Commit 31dad809 by Jakub Jelinek Committed by Jakub Jelinek

re PR ipa/60457 (ICE in cgraph_get_node)

	PR ipa/60457
	* ipa.c (symtab_remove_unreachable_nodes): Don't call
	cgraph_get_create_node on VAR_DECLs.

	* g++.dg/ipa/pr60457.C: New test.

From-SVN: r208454
parent 3c1c08d6
2014-03-10 Jakub Jelinek <jakub@redhat.com>
PR ipa/60457
* ipa.c (symtab_remove_unreachable_nodes): Don't call
cgraph_get_create_node on VAR_DECLs.
2014-03-10 Richard Biener <rguenther@suse.de>
PR middle-end/60474
......
......@@ -354,7 +354,8 @@ symtab_remove_unreachable_nodes (bool before_inlining_p, FILE *file)
node->aux = (void *)2;
else
{
if (DECL_ABSTRACT_ORIGIN (node->decl))
if (TREE_CODE (node->decl) == FUNCTION_DECL
&& DECL_ABSTRACT_ORIGIN (node->decl))
{
struct cgraph_node *origin_node
= cgraph_get_create_node (DECL_ABSTRACT_ORIGIN (node->decl));
......
2014-03-10 Jakub Jelinek <jakub@redhat.com>
PR ipa/60457
* g++.dg/ipa/pr60457.C: New test.
2014-03-10 Richard Biener <rguenther@suse.de>
PR middle-end/60474
......
// PR ipa/60457
// { dg-do compile }
template <class T>
struct A
{
};
struct B : A <B>
{
B ();
};
B::B ()
{
const int c[] = { 1, 1 };
}
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