OSDN Git Service

* ipa-inline.c (cgraph_decide_inlining_incrementally): When optimizing
authorhubicka <hubicka@138bc75d-0d04-0410-961f-82ee72b054a4>
Fri, 3 Jul 2009 20:28:14 +0000 (20:28 +0000)
committerhubicka <hubicka@138bc75d-0d04-0410-961f-82ee72b054a4>
Fri, 3 Jul 2009 20:28:14 +0000 (20:28 +0000)
for size, reduce amount of inlining.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@149210 138bc75d-0d04-0410-961f-82ee72b054a4

gcc/ChangeLog
gcc/ipa-inline.c

index 493d1b2..31307ae 100644 (file)
@@ -1,3 +1,8 @@
+2009-07-03  Jan Hubicka  <jh@suse.cz>
+
+       * ipa-inline.c (cgraph_decide_inlining_incrementally): When optimizing
+       for size, reduce amount of inlining.
+
 2009-07-03  Richard Guenther  <rguenther@suse.de>
 
        PR middle-end/34163
index 28f0ec9..040096f 100644 (file)
@@ -1504,7 +1504,8 @@ cgraph_decide_inlining_incrementally (struct cgraph_node *node,
            continue;
          }
 
-       if (cgraph_maybe_hot_edge_p (e) && leaf_node_p (e->callee))
+       if (cgraph_maybe_hot_edge_p (e) && leaf_node_p (e->callee)
+           && optimize_function_for_speed_p (cfun))
          allowed_growth = PARAM_VALUE (PARAM_EARLY_INLINING_INSNS);
 
        /* When the function body would grow and inlining the function won't