mirror of
https://github.com/edk2-porting/linux-next.git
synced 2024-11-27 12:04:22 +08:00
gcc-plugins/stackleak: Provide verbose mode
In order to compare instrumentation between builds, make the verbose mode of the plugin available during the build. This is rarely needed (behind EXPERT) and very noisy (disabled for COMPILE_TEST). Cc: Alexander Popov <alex.popov@linux.com> Signed-off-by: Kees Cook <keescook@chromium.org>
This commit is contained in:
parent
26291c54e1
commit
f154066b61
@ -37,6 +37,8 @@ gcc-plugin-cflags-$(CONFIG_GCC_PLUGIN_STACKLEAK) \
|
|||||||
+= -fplugin-arg-stackleak_plugin-track-min-size=$(CONFIG_STACKLEAK_TRACK_MIN_SIZE)
|
+= -fplugin-arg-stackleak_plugin-track-min-size=$(CONFIG_STACKLEAK_TRACK_MIN_SIZE)
|
||||||
gcc-plugin-cflags-$(CONFIG_GCC_PLUGIN_STACKLEAK) \
|
gcc-plugin-cflags-$(CONFIG_GCC_PLUGIN_STACKLEAK) \
|
||||||
+= -fplugin-arg-stackleak_plugin-arch=$(SRCARCH)
|
+= -fplugin-arg-stackleak_plugin-arch=$(SRCARCH)
|
||||||
|
gcc-plugin-cflags-$(CONFIG_GCC_PLUGIN_STACKLEAK_VERBOSE) \
|
||||||
|
+= -fplugin-arg-stackleak_plugin-verbose
|
||||||
ifdef CONFIG_GCC_PLUGIN_STACKLEAK
|
ifdef CONFIG_GCC_PLUGIN_STACKLEAK
|
||||||
DISABLE_STACKLEAK_PLUGIN += -fplugin-arg-stackleak_plugin-disable
|
DISABLE_STACKLEAK_PLUGIN += -fplugin-arg-stackleak_plugin-disable
|
||||||
endif
|
endif
|
||||||
|
@ -174,6 +174,16 @@ config GCC_PLUGIN_STACKLEAK
|
|||||||
* https://grsecurity.net/
|
* https://grsecurity.net/
|
||||||
* https://pax.grsecurity.net/
|
* https://pax.grsecurity.net/
|
||||||
|
|
||||||
|
config GCC_PLUGIN_STACKLEAK_VERBOSE
|
||||||
|
bool "Report stack depth analysis instrumentation" if EXPERT
|
||||||
|
depends on GCC_PLUGIN_STACKLEAK
|
||||||
|
depends on !COMPILE_TEST # too noisy
|
||||||
|
help
|
||||||
|
This option will cause a warning to be printed each time the
|
||||||
|
stackleak plugin finds a function it thinks needs to be
|
||||||
|
instrumented. This is useful for comparing coverage between
|
||||||
|
builds.
|
||||||
|
|
||||||
config STACKLEAK_TRACK_MIN_SIZE
|
config STACKLEAK_TRACK_MIN_SIZE
|
||||||
int "Minimum stack frame size of functions tracked by STACKLEAK"
|
int "Minimum stack frame size of functions tracked by STACKLEAK"
|
||||||
default 100
|
default 100
|
||||||
|
Loading…
Reference in New Issue
Block a user