Commit ec1d732b by Jan Hubicka Committed by Jan Hubicka

re PR ipa/62121 (ICE: Segmentation fault in ipa-devirt.c:997)


	PR ipa/62121
	* ipa-polymorphic-call.c (ipa_polymorphic_call_context::restrict_to_inner_class):
	fix pasto in checking array size.

	* g++.dg/torture/pr62121.C: New testcase.

From-SVN: r215655
parent ee5bd6c8
2014-09-26 Jan Hubicka <hubicka@ucw.cz> 2014-09-26 Jan Hubicka <hubicka@ucw.cz>
PR ipa/62121
* ipa-polymorphic-call.c (ipa_polymorphic_call_context::restrict_to_inner_class):
fix pasto in checking array size.
2014-09-26 Jan Hubicka <hubicka@ucw.cz>
PR middle-end/35545 PR middle-end/35545
* passes.def (pass_tracer): Move before last dominator pass. * passes.def (pass_tracer): Move before last dominator pass.
...@@ -327,7 +327,7 @@ ipa_polymorphic_call_context::restrict_to_inner_class (tree expected_type) ...@@ -327,7 +327,7 @@ ipa_polymorphic_call_context::restrict_to_inner_class (tree expected_type)
&& (cur_offset && (cur_offset
+ (expected_type ? tree_to_uhwi (TYPE_SIZE (expected_type)) + (expected_type ? tree_to_uhwi (TYPE_SIZE (expected_type))
: 0) : 0)
> tree_to_uhwi (TYPE_SIZE (type)))) > tree_to_uhwi (TYPE_SIZE (subtype))))
goto no_useful_type_info; goto no_useful_type_info;
cur_offset = new_offset; cur_offset = new_offset;
......
2014-09-26 Jan Hubicka <hubicka@ucw.cz> 2014-09-26 Jan Hubicka <hubicka@ucw.cz>
PR ipa/62121
* g++.dg/torture/pr62121.C: New testcase.
2014-09-26 Jan Hubicka <hubicka@ucw.cz>
PR middle-end/35545 PR middle-end/35545
* g++.dg/tree-prof/pr35545.C: New testcase. * g++.dg/tree-prof/pr35545.C: New testcase.
......
// { dg-do compile }
class A
{
virtual double operator()();
};
class B : A
{
public:
double operator()();
};
extern B a[];
int b = a[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