From bc65659a46f32680ecf58dff2bc7a5e98c9fcaa9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pawe=C5=82=20Dziepak?= Date: Wed, 7 Feb 2018 10:26:28 +0000 Subject: [PATCH] configure.py: set inline-unit-growth to 300 It has been discovered that the compiler is too conservative when deciding which functions to inline. In particular, the limiting tunable turned out to be inline-unit-growth which limits inlining in large translation units. --- configure.py | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/configure.py b/configure.py index 71077f8698..64db7811a9 100755 --- a/configure.py +++ b/configure.py @@ -776,6 +776,14 @@ warnings = [w warnings = ' '.join(warnings + ['-Wno-error=deprecated-declarations']) +optimization_flags = [ + '--param inline-unit-growth=300', +] +optimization_flags = [o + for o in optimization_flags + if flag_supported(flag = o, compiler = args.cxx)] +modes['release']['opt'] += ' ' + ' '.join(optimization_flags) + gold_linker_flag = gold_supported(compiler = args.cxx) dbgflag = debug_flag(args.cxx) if args.debuginfo else ''