Commit 760e1bb7 by Richard Biener Committed by Richard Biener

re PR lto/67699 (ICE (segfault) compiling a const array with -flto)

2015-09-24  Richard Biener  <rguenther@suse.de>

	PR lto/67699
	* lto-cgraph.c (compute_ltrans_boundary): Do not stream
	abstract origins.

	* g++.dg/pr67699.C: New testcase.

From-SVN: r228084
parent 4dfe21ac
2015-09-24 Richard Biener <rguenther@suse.de>
PR lto/67699
* lto-cgraph.c (compute_ltrans_boundary): Do not stream
abstract origins.
2015-09-24 Thomas Schwinge <thomas@codesourcery.com>
* tree-object-size.c (plus_stmt_object_size)
......@@ -895,14 +895,6 @@ compute_ltrans_boundary (lto_symtab_encoder_t in_encoder)
add_node_to (encoder, node, true);
lto_set_symtab_encoder_in_partition (encoder, node);
create_references (encoder, node);
/* For proper debug info, we need to ship the origins, too. */
if (DECL_ABSTRACT_ORIGIN (node->decl))
{
struct cgraph_node *origin_node
= cgraph_node::get_create (DECL_ABSTRACT_ORIGIN (node->decl));
origin_node->used_as_abstract_origin = true;
add_node_to (encoder, origin_node, true);
}
}
for (lsei = lsei_start_variable_in_partition (in_encoder);
!lsei_end_p (lsei); lsei_next_variable_in_partition (&lsei))
......@@ -914,13 +906,6 @@ compute_ltrans_boundary (lto_symtab_encoder_t in_encoder)
lto_set_symtab_encoder_in_partition (encoder, vnode);
lto_set_symtab_encoder_encode_initializer (encoder, vnode);
create_references (encoder, vnode);
/* For proper debug info, we need to ship the origins, too. */
if (DECL_ABSTRACT_ORIGIN (vnode->decl))
{
varpool_node *origin_node
= varpool_node::get (DECL_ABSTRACT_ORIGIN (vnode->decl));
lto_set_symtab_encoder_in_partition (encoder, origin_node);
}
}
/* Pickle in also the initializer of all referenced readonly variables
to help folding. Constant pool variables are not shared, so we must
......
2015-09-24 Richard Biener <rguenther@suse.de>
PR lto/67699
* g++.dg/pr67699.C: New testcase.
2015-09-24 Richard Earnshaw <rearnsha@arm.com>
PR libgcc/67624
......
// { dg-do compile }
// { dg-require-effective-target lto }
// { dg-options "-flto" }
template <class T> class foo {
foo() { int const bar[2] = {1, 1}; }
};
template class foo<int>;
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