Commit fd0c2f00 by Richard Biener Committed by Richard Biener

re PR middle-end/65555 (ICE: verify_gimple failed (LHS in noreturn call))

2015-03-26  Richard Biener  <rguenther@suse.de>

	PR middle-end/65555
	* tree-cfg.c (verify_gimple_call): Do not require a call to
	have no LHS if it wasn't recognized as control altering yet.

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

From-SVN: r221697
parent 672ff0b6
2015-03-26 Richard Biener <rguenther@suse.de>
PR middle-end/65555
* tree-cfg.c (verify_gimple_call): Do not require a call to
have no LHS if it wasn't recognized as control altering yet.
2015-03-26 Jakub Jelinek <jakub@redhat.com> 2015-03-26 Jakub Jelinek <jakub@redhat.com>
PR tree-optimization/64715 PR tree-optimization/64715
......
2015-03-26 Richard Biener <rguenther@suse.de>
PR middle-end/65555
* g++.dg/torture/pr65555.C: New testcase.
2015-03-26 Jakub Jelinek <jakub@redhat.com> 2015-03-26 Jakub Jelinek <jakub@redhat.com>
PR tree-optimization/64715 PR tree-optimization/64715
......
// { dg-do compile }
class basic_ostream {
public:
basic_ostream &operator<<(basic_ostream &p1(basic_ostream &)) {
return p1(*this);
}
} a;
void fn1() __attribute__((__noreturn__));
basic_ostream &fn2(basic_ostream &) { fn1(); }
void fn3() { a << fn2; }
...@@ -3335,7 +3335,9 @@ verify_gimple_call (gcall *stmt) ...@@ -3335,7 +3335,9 @@ verify_gimple_call (gcall *stmt)
return true; return true;
} }
if (gimple_call_lhs (stmt) && gimple_call_noreturn_p (stmt)) if (gimple_call_ctrl_altering_p (stmt)
&& gimple_call_lhs (stmt)
&& gimple_call_noreturn_p (stmt))
{ {
error ("LHS in noreturn call"); error ("LHS in noreturn call");
return true; return true;
......
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