[pretty-ipa] Fix inliner double accounting problem

Jan Hubicka hubicka@ucw.cz
Tue Apr 6 11:00:00 GMT 2010


Hi,
I've commited the following patch to pretty-ipa to fix inliner double accounting the savings caused
by eliminating needs for offline copy of a function.  For tramp3d I also need to bump unit growht
to 50% to get same results as before.

I've also merged from mainline today to get tramp3d compiling again.

Bootstrapped/regtested x86_64-linux.

        * tree-inline.c (cgraph_mark_inline_edge): Do not update overall size for fully
        inlined functions.
        * params.def (PARAM_INLINE_UNIT_GROWTH): Set to 50%.

Index: ipa-inline.c
===================================================================
--- ipa-inline.c	(revision 157985)
+++ ipa-inline.c	(working copy)
@@ -336,8 +336,6 @@ cgraph_mark_inline_edge (struct cgraph_e
   gcc_assert (what->global.inlined_to == to);
   if (new_size > old_size)
     overall_size += new_size - old_size;
-  if (!duplicate)
-    overall_size -= orig_size;
   ncalls_inlined++;
 
   if (flag_indirect_inlining)
Index: params.def
===================================================================
--- params.def	(revision 157985)
+++ params.def	(working copy)
@@ -177,7 +177,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)
+	 50, 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)",



More information about the Gcc-patches mailing list