Commit c1eed5a1 by Jan Hubicka Committed by Jan Hubicka

re PR ipa/64686 (ICE: in edge_badness, at ipa-inline.c:912 during Firefox LTO…

re PR ipa/64686 (ICE: in edge_badness, at ipa-inline.c:912 during Firefox LTO build with enabled checking)

	PR ipa/64686
	* ipa-inline.c (inline_small_functions): Fix ordering issue between
	speculation resolution and key updates.
	* g++.dg/torture/pr64686.C: New testcase.

From-SVN: r220429
parent 73d098df
2015-02-04 Jan Hubicka <hubicka@ucw.cz>
PR ipa/64686
* ipa-inline.c (inline_small_functions): Fix ordering issue between
speculation resolution and key updates.
2015-02-04 Jan Hubicka <hubicka@ucw.cz>
* ipa-prop.c (update_indirect_edges_after_inlining): By more careful
about not letting any speculative edges unupdated.
......
......@@ -1702,6 +1702,7 @@ inline_small_functions (void)
{
bool update = false;
struct cgraph_edge *next;
bool has_speculative = false;
if (dump_file)
fprintf (dump_file, "Enqueueing calls in %s/%i.\n",
......@@ -1719,12 +1720,17 @@ inline_small_functions (void)
gcc_assert (!edge->aux);
update_edge_key (&edge_heap, edge);
}
if (edge->speculative && !speculation_useful_p (edge, edge->aux != NULL))
if (edge->speculative)
has_speculative = true;
}
if (has_speculative)
for (edge = node->callees; edge; edge = next)
if (edge->speculative && !speculation_useful_p (edge,
edge->aux != NULL))
{
edge->resolve_speculation ();
update = true;
}
}
if (update)
{
struct cgraph_node *where = node->global.inlined_to
......
2015-02-04 Jan Hubicka <hubicka@ucw.cz>
PR ipa/64686
* g++.dg/torture/pr64686.C: New testcase.
2015-02-04 H.J. Lu <hongjiu.lu@intel.com>
PR rtl-optimization/64905
......
// { dg-do compile }
class A
{
protected:
A *m_fn2 (int) const;
public:
virtual A *m_fn1 (int *) const = 0;
};
class B : A
{
B (A *, int, A *);
A *m_fn1 (int *) const;
};
A *
B::m_fn1 (int *) const
{
new B (m_fn2 (0)->m_fn1 (0), 0, m_fn2 (0)->m_fn1 (0));
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment