diff mbox

Reduce inline-unit-growth to 15%

Message ID 20150119221355.GE23365@kam.mff.cuni.cz
State New
Headers show

Commit Message

Jan Hubicka Jan. 19, 2015, 10:13 p.m. UTC
Hi,
this patch reduces unit growth to 15%.  This is important change for LTO builds.
For example Firefox binary reduces by about 10%. I hope this change is now
safe with increased early-inlining-insns and improvements in inline analysis.
I benchmarked this on Firefox, majority of C++ testsuite and Martin did
Spec2k6 testing.  All those indicate noticeable code size reductions and I
am not aware of important perfromance issues.

The importance of this change for LTO comes from fact that single unit
compilation hardly meets the limit unless the program is heavy user of C++
abstractions (like tramp3d or DLV), but with LTO all functions became
cross-module inlinable and even C programs suffers from large code bloat caused
by tons of cross-module inlining which is not really desirable in all cases.

I will wait for nightly testers to pick the results up, but really hope it is
possible to reduce the default this time.

Bootstrapped/regtested x86_64-linux.

Honza

	* params.def (inline-unit-growth): Drop to 15%.
	* invoke.texi (inline-unit-growth): Document change.
diff mbox

Patch

Index: params.def
===================================================================
--- params.def	(revision 219826)
+++ params.def	(working copy)
@@ -190,7 +190,7 @@  DEFPARAM(PARAM_LARGE_UNIT_INSNS,
 DEFPARAM(PARAM_INLINE_UNIT_GROWTH,
 	 "inline-unit-growth",
 	 "How much can given compilation unit grow because of the inlining (in percent)",
-	 30, 0, 0)
+	 15, 0, 0)
 DEFPARAM(PARAM_IPCP_UNIT_GROWTH,
 	 "ipcp-unit-growth",
 	 "How much can given compilation unit grow because of the interprocedural constant propagation (in percent)",
Index: doc/invoke.texi
===================================================================
--- doc/invoke.texi	(revision 219826)
+++ doc/invoke.texi	(working copy)
@@ -10001,7 +10001,7 @@  before applying @option{--param inline-u
 
 @item inline-unit-growth
 Specifies maximal overall growth of the compilation unit caused by inlining.
-The default value is 30 which limits unit growth to 1.3 times the original
+The default value is 15 which limits unit growth to 1.15 times the original
 size. Cold functions (either marked cold via an attribute or by profile
 feedback) are not accounted into the unit size.