diff options
author | Alexander Popov <alex.popov@linux.com> | 2018-07-11 23:36:39 +0300 |
---|---|---|
committer | Kees Cook <keescook@chromium.org> | 2018-07-24 16:14:06 -0700 |
commit | ba7d150a1010d760836a722e24a8253c516a3238 (patch) | |
tree | 2fe55fdd3553a1cc1f4901eadf17eede51483967 /scripts | |
parent | 959c413db91e6b336150110442f9289f57e43199 (diff) | |
download | linux-next-ba7d150a1010d760836a722e24a8253c516a3238.tar.gz |
fs/proc: Show STACKLEAK metrics in the /proc file system
Introduce CONFIG_STACKLEAK_METRICS providing STACKLEAK information about
tasks via the /proc file system. In particular, /proc/<pid>/stack_depth
shows the maximum kernel stack consumption for the current and previous
syscalls. Although this information is not precise, it can be useful for
estimating the STACKLEAK performance impact for your workloads.
Signed-off-by: Alexander Popov <alex.popov@linux.com>
Signed-off-by: Kees Cook <keescook@chromium.org>
Diffstat (limited to 'scripts')
-rw-r--r-- | scripts/gcc-plugins/Kconfig | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/scripts/gcc-plugins/Kconfig b/scripts/gcc-plugins/Kconfig index c0a259759e61..2535b9d75c1b 100644 --- a/scripts/gcc-plugins/Kconfig +++ b/scripts/gcc-plugins/Kconfig @@ -173,4 +173,16 @@ config STACKLEAK_TRACK_MIN_SIZE a stack frame size greater than or equal to this parameter. If unsure, leave the default value 100. +config STACKLEAK_METRICS + bool "Show STACKLEAK metrics in the /proc file system" + depends on GCC_PLUGIN_STACKLEAK + depends on PROC_FS + help + If this is set, STACKLEAK metrics for every task are available in + the /proc file system. In particular, /proc/<pid>/stack_depth + shows the maximum kernel stack consumption for the current and + previous syscalls. Although this information is not precise, it + can be useful for estimating the STACKLEAK performance impact for + your workloads. + endif |