[libvirt PATCH 1/6] meson: Allow larger stack frames when instrumenting

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



When enabling sanitizers, gcc adds some instrumentation to the code
that may enlarge stack frames. Some function's stack frames are already
close to the limit of 4096 and are enlarged past that threshold,
e.g. virLXCProcessStart which reaches a frame size of 4624 bytes.

Signed-off-by: Tim Wiederhake <twiederh@xxxxxxxxxx>
---
 meson.build | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/meson.build b/meson.build
index 618cbd6b1d..bbdbe4afd8 100644
--- a/meson.build
+++ b/meson.build
@@ -278,7 +278,8 @@ cc_flags += [
   '-Wformat-y2k',
   '-Wformat-zero-length',
   '-Wframe-address',
-  '-Wframe-larger-than=4096',
+  # sanitizer instrumentation may enlarge stack frames
+  '-Wframe-larger-than=@0@'.format(get_option('b_sanitize') in ['', 'none'] ? 4096 : 8192),
   '-Wfree-nonheap-object',
   '-Whsa',
   '-Wif-not-aligned',
-- 
2.26.3




[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]

  Powered by Linux