Files
kernel_arpi/include/trace/hooks
Quentin Perret d6a300eb7a ANDROID: Disable CFI on restricted vendor hooks
CFI has additional overhead on indirect branches to modules as the
target is not known at kernel compile-time. This has been demonstrated
to cause problematic performance regressions on benchmarks using GKI
together with modularized scheduler callbacks attached to restricted
vendor hooks.

To restore some of the performance back, let's disable CFI around the
restricted hook call sites and issue a raw indirect call in fast paths.

We should be able to drop this patch when/if the arm64 static_call
port lands upstream [1] as this would make tracepoints circumvent some
of the CFI checks using text patching, but that still remain to be
proven.

[1] https://lore.kernel.org/linux-arm-kernel/20201028184114.6834-1-ardb@kernel.org/

Bug: 168521642
Change-Id: I7cd59f582b12fed15be64059f08122f96786e650
Signed-off-by: Quentin Perret <qperret@google.com>
2022-05-16 15:28:06 +00:00
..
2022-04-22 18:12:36 +08:00