[Bug rtl-optimization/56571] [4.7/4.8 Regression] ICE in copyprop_hardreg_forward_1, at regcprop.c (insn does not satisfy its constraints !)

2013-03-12 Thread hubicka at gcc dot gnu.org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=56571



--- Comment #5 from Jan Hubicka hubicka at gcc dot gnu.org 2013-03-12 
12:13:44 UTC ---

Author: hubicka

Date: Tue Mar 12 12:13:33 2013

New Revision: 196612



URL: http://gcc.gnu.org/viewcvs?root=gccview=revrev=196612

Log:

PR middle-end/56571

* valtrack.c (cleanup_auto_inc_dec): Unshare clobbers originating

from pseudos.

* emit-rtl.c (verify_rtx_sharing): Likewise.

(copy_insn_1): Likewise.

* rtl.c (copy_rtx): Likewise.

PR middle-end/56571

* gcc.c-torture/compile/pr56571.c: New testcase.



Added:

trunk/gcc/testsuite/gcc.c-torture/compile/pr56571.c

Modified:

trunk/gcc/ChangeLog

trunk/gcc/emit-rtl.c

trunk/gcc/rtl.c

trunk/gcc/testsuite/ChangeLog

trunk/gcc/valtrack.c


[Bug rtl-optimization/56571] [4.7/4.8 Regression] ICE in copyprop_hardreg_forward_1, at regcprop.c (insn does not satisfy its constraints !)

2013-03-12 Thread hubicka at gcc dot gnu.org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=56571



Jan Hubicka hubicka at gcc dot gnu.org changed:



   What|Removed |Added



 Status|NEW |RESOLVED

 CC||hubicka at gcc dot gnu.org

 Resolution||FIXED



--- Comment #6 from Jan Hubicka hubicka at gcc dot gnu.org 2013-03-12 
12:15:16 UTC ---

Fixed.


[Bug rtl-optimization/56571] [4.7/4.8 Regression] ICE in copyprop_hardreg_forward_1, at regcprop.c (insn does not satisfy its constraints !)

2013-03-08 Thread rguenth at gcc dot gnu.org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=56571



Richard Biener rguenth at gcc dot gnu.org changed:



   What|Removed |Added



 Target||x86_64-*-*

 Status|UNCONFIRMED |NEW

   Last reconfirmed||2013-03-08

  Known to work||4.6.4

   Target Milestone|--- |4.7.3

Summary|ICE in  |[4.7/4.8 Regression] ICE in

   |copyprop_hardreg_forward_1, |copyprop_hardreg_forward_1,

   |at regcprop.c (insn does|at regcprop.c (insn does

   |not satisfy its constraints |not satisfy its constraints

   |!)  |!)

 Ever Confirmed|0   |1



--- Comment #1 from Richard Biener rguenth at gcc dot gnu.org 2013-03-08 
11:24:42 UTC ---

Confirmed.


[Bug rtl-optimization/56571] [4.7/4.8 Regression] ICE in copyprop_hardreg_forward_1, at regcprop.c (insn does not satisfy its constraints !)

2013-03-08 Thread jakub at gcc dot gnu.org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=56571



--- Comment #2 from Jakub Jelinek jakub at gcc dot gnu.org 2013-03-08 
12:08:53 UTC ---

Started with http://gcc.gnu.org/viewcvs?root=gccview=revrev=181188


[Bug rtl-optimization/56571] [4.7/4.8 Regression] ICE in copyprop_hardreg_forward_1, at regcprop.c (insn does not satisfy its constraints !)

2013-03-08 Thread jakub at gcc dot gnu.org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=56571



Jakub Jelinek jakub at gcc dot gnu.org changed:



   What|Removed |Added



 CC||bernds at gcc dot gnu.org,

   ||jakub at gcc dot gnu.org,

   ||steven at gcc dot gnu.org



--- Comment #3 from Jakub Jelinek jakub at gcc dot gnu.org 2013-03-08 
14:49:10 UTC ---

Sounds like regrename.c bug.  This pass changes:

83: {flags:CCZ=cmp(ax:SI|cx:SI,0);clobber ax:SI;}

instruction (iorsi_3) into:

83: {flags:CCZ=cmp(si:SI|cx:SI,0);clobber r10:SI;}

which of course doesn't work, the pattern has =r constraint on the clobber,

and %0 and rme constraints on the comparison operands, so it requires that

the clobber matches one of the registers.

I'm quite surprised not to see any validate_change calls in the whole

regrename.c, how does it ensure that what it changes is actually valid?


[Bug rtl-optimization/56571] [4.7/4.8 Regression] ICE in copyprop_hardreg_forward_1, at regcprop.c (insn does not satisfy its constraints !)

2013-03-08 Thread jakub at gcc dot gnu.org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=56571



--- Comment #4 from Jakub Jelinek jakub at gcc dot gnu.org 2013-03-08 
16:06:33 UTC ---

Ok, it seems to be caused by rtl sharing of the clobber, which has been

introduced by Honza: http://gcc.gnu.org/ml/gcc-patches/2004-01/msg01918.html

Honza is going to try sharing only clobbers of hard regs that don't have

ORIGINAL_REGNO set on them and disallow sharing anything else (plus copy it on

copy_rtx etc.).