[Bug c++/69211] [6 Regression] g++ ICE on x86_64-linux-gnu (verify_gimple failed)

2016-01-11 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69211

Jakub Jelinek  changed:

   What|Removed |Added

 CC||jakub at gcc dot gnu.org

--- Comment #2 from Jakub Jelinek  ---
Started with r230365.  I'll have a look.

[Bug c++/69211] [6 Regression] g++ ICE on x86_64-linux-gnu (verify_gimple failed)

2016-01-11 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69211

--- Comment #3 from Jakub Jelinek  ---
I guess the bug is that lots of code in fold-const.c is totally unprepared to
see NOP_EXPR wrapping up INTEGER_CST (or other constants), it assumes that if
argN is say INTEGER_CST, then argN == opN and thus does not fold.
Rather than changing everything in fold-const.c, I think it is better to make
sure cp_fold folds those away early enough.  Let me test a patch.

[Bug c++/69211] [6 Regression] g++ ICE on x86_64-linux-gnu (verify_gimple failed)

2016-01-11 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69211

Jakub Jelinek  changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 Resolution|--- |FIXED

--- Comment #5 from Jakub Jelinek  ---
Fixed.

[Bug c++/69211] [6 Regression] g++ ICE on x86_64-linux-gnu (verify_gimple failed)

2016-01-11 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69211

--- Comment #4 from Jakub Jelinek  ---
Author: jakub
Date: Mon Jan 11 17:59:22 2016
New Revision: 232237

URL: https://gcc.gnu.org/viewcvs?rev=232237=gcc=rev
Log:
PR c++/69211
* cp-gimplify.c (cp_fold): If COMPOUND_EXPR or MODIFY_EXPR
folded operands have side-effects, but folding changed any of them,
build a new tree with the folded operands instead of returning the
unfolded tree.

* g++.dg/opt/pr69211.C: New test.

Added:
trunk/gcc/testsuite/g++.dg/opt/pr69211.C
Modified:
trunk/gcc/cp/ChangeLog
trunk/gcc/cp/cp-gimplify.c
trunk/gcc/testsuite/ChangeLog

[Bug c++/69211] [6 Regression] g++ ICE on x86_64-linux-gnu (verify_gimple failed)

2016-01-09 Thread pinskia at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69211

Andrew Pinski  changed:

   What|Removed |Added

   Keywords||ice-on-valid-code
 Status|UNCONFIRMED |NEW
   Last reconfirmed||2016-01-09
  Component|middle-end  |c++
   Target Milestone|--- |6.0
Summary|g++ ICE on x86_64-linux-gnu |[6 Regression] g++ ICE on
   |(verify_gimple failed)  |x86_64-linux-gnu
   ||(verify_gimple failed)
 Ever confirmed|0   |1

--- Comment #1 from Andrew Pinski  ---
Confirmed.  Also on aarch64-linux-gnu.