Skip to content

Commit ae94b26

Browse files
dvyukovKAGA-KOKO
authored andcommitted
x86: Ignore stack unwinding in KCOV
Stack unwinding produces large amounts of uninteresting coverage. It's called from KASAN kmalloc/kfree hooks, fault injection, etc. It's not particularly useful and is not a function of system call args. Ignore that code. Signed-off-by: Dmitry Vyukov <[email protected]> Signed-off-by: Thomas Gleixner <[email protected]> Reviewed-by: Alexander Potapenko <[email protected]> Reviewed-by: Marco Elver <[email protected]> Reviewed-by: Andrey Konovalov <[email protected]> Acked-by: Peter Zijlstra (Intel) <[email protected]> Link: https://lore.kernel.org/all/eaf54b8634970b73552dcd38bf9be6ef55238c10.1718092070.git.dvyukov@google.com
1 parent f34d086 commit ae94b26

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

arch/x86/kernel/Makefile

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,14 @@ KMSAN_SANITIZE_nmi.o := n
3535
# If instrumentation of the following files is enabled, boot hangs during
3636
# first second.
3737
KCOV_INSTRUMENT_head$(BITS).o := n
38+
# These are called from save_stack_trace() on debug paths,
39+
# and produce large amounts of uninteresting coverage.
40+
KCOV_INSTRUMENT_stacktrace.o := n
41+
KCOV_INSTRUMENT_dumpstack.o := n
42+
KCOV_INSTRUMENT_dumpstack_$(BITS).o := n
43+
KCOV_INSTRUMENT_unwind_orc.o := n
44+
KCOV_INSTRUMENT_unwind_frame.o := n
45+
KCOV_INSTRUMENT_unwind_guess.o := n
3846

3947
CFLAGS_irq.o := -I $(src)/../include/asm/trace
4048

0 commit comments

Comments
 (0)