+2011-12-07 Richard Guenther <rguenther@suse.de>
+
+ PR tree-optimization/50823
+ * ipa-inline.c (edge_badness): Do not account for the number of
+ remaining calls.
+
2011-12-07 Martin Jambor <mjambor@suse.cz>
PR tree-optimization/50744
else if (flag_guess_branch_prob)
{
int div = edge->frequency * (1<<10) / CGRAPH_FREQ_MAX;
- int growth_for_all;
div = MAX (div, 1);
gcc_checking_assert (edge->frequency <= CGRAPH_FREQ_MAX);
if (dump)
fprintf (dump_file, "Badness overflow\n");
}
- growth_for_all = estimate_growth (callee);
- badness += growth_for_all;
if (dump)
{
fprintf (dump_file,
- " %i: guessed profile. frequency %f, overall growth %i,"
+ " %i: guessed profile. frequency %f,"
" benefit %f%%, divisor %i\n",
- (int) badness, (double)edge->frequency / CGRAPH_FREQ_BASE, growth_for_all,
+ (int) badness, (double)edge->frequency / CGRAPH_FREQ_BASE,
relative_time_benefit (callee_info, edge, time_growth) * 100 / 256.0, div);
}
}
+2011-12-07 Richard Guenther <rguenther@suse.de>
+
+ PR tree-optimization/50823
+ * gcc.dg/torture/pr50823.c: New testcase.
+
2011-12-07 Martin Jambor <mjambor@suse.cz>
PR tree-optimization/50744
--- /dev/null
+/* { dg-do compile } */
+/* { dg-options "-finline-functions" } */
+
+int k1, k2, k3, k4, k5, k6, k7, k8;
+
+void set_first_insn (int);
+void set_last_insn (void);
+
+static int make_insn_raw (void)
+{
+ set_first_insn (0);
+ set_last_insn ();
+ return k1;
+}
+
+static void add_insn_after (void)
+{
+ if (k2)
+ k3 = k4;
+
+ if (k5)
+ k6 = k7;
+}
+
+void emit_pattern_after_noloc (int (make_raw) (void))
+{
+ if (k8)
+ {
+ make_raw ();
+ add_insn_after ();
+ }
+}
+
+void emit_insn_after_noloc (void)
+{
+ emit_pattern_after_noloc (make_insn_raw);
+}
+
+void emit_debug_insn_before_setloc (int k9)
+{
+ if (k9)
+ make_insn_raw ();
+}