[Bug target/39076] internal compiler error when cross-compiling flac
--- Comment #6 from ramana dot r at gmail dot com 2009-02-04 08:34 --- (In reply to comment #5) > (In reply to comment #4) > > > Looking at the dumps this rtx is generated by the rename registers pass in > > 4.3.x . In trunk however rename register does not generate this rtx and > > hence > > there is no problem. It could still be latent but one has to dig deeper. > > A quick comparison of trunk and gcc 4.3 branch shows the following patch being > applied in trunk vs. the 4.3 branch. > > http://gcc.gnu.org/ml/gcc-patches/2008-04/msg01577.html > > A quick check with the patch at > > ram...@numenor:~/cos/mycos/gcc/gcc$ svn diff -r137128:137235 regrename.c > Index: regrename.c > === > --- regrename.c (revision 137128) > +++ regrename.c (revision 137235) > @@ -812,7 +812,7 @@ > OP_IN, 0); > > for (i = 0; i < recog_data.n_dups; i++) > - *recog_data.dup_loc[i] = copy_rtx (old_dups[i]); > + *recog_data.dup_loc[i] = old_dups[i]; > for (i = 0; i < n_ops; i++) > *recog_data.operand_loc[i] = old_operands[i]; > if (recog_data.n_dups) > Related discussions and patch proposed here. http://gcc.gnu.org/ml/gcc/2009-02/msg00074.html This is essentially a backport of a patch in trunk - A full bootstrap and regression test is underway. I've confirmed that this patch fixes the ICE mentioned with the ARM port. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=39076
[Bug target/39076] internal compiler error when cross-compiling flac
--- Comment #5 from ramana dot r at gmail dot com 2009-02-03 22:06 --- (In reply to comment #4) > Looking at the dumps this rtx is generated by the rename registers pass in > 4.3.x . In trunk however rename register does not generate this rtx and hence > there is no problem. It could still be latent but one has to dig deeper. A quick comparison of trunk and gcc 4.3 branch shows the following patch being applied in trunk vs. the 4.3 branch. http://gcc.gnu.org/ml/gcc-patches/2008-04/msg01577.html A quick check with the patch at ram...@numenor:~/cos/mycos/gcc/gcc$ svn diff -r137128:137235 regrename.c Index: regrename.c === --- regrename.c (revision 137128) +++ regrename.c (revision 137235) @@ -812,7 +812,7 @@ OP_IN, 0); for (i = 0; i < recog_data.n_dups; i++) - *recog_data.dup_loc[i] = copy_rtx (old_dups[i]); + *recog_data.dup_loc[i] = old_dups[i]; for (i = 0; i < n_ops; i++) *recog_data.operand_loc[i] = old_operands[i]; if (recog_data.n_dups) -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=39076
[Bug target/39076] internal compiler error when cross-compiling flac
--- Comment #4 from ramana dot r at gmail dot com 2009-02-03 21:43 --- (In reply to comment #2) > No problem with the trunk, but it's still there in the 4.3 branch. > > Here's a test case. Requires -funroll-loops -Os, no problem with any other > -O, > or without -funroll-loops, curiously. > > int f(int x, int y) { > int bytes = 4 * x + y; > if (bytes == 0) > return 0; > return bytes + 1; > } > I get the same problem even with a arm-none-eabi toolchain with the 4.3 branch only. For this particular testcase, the ICE is generated in final.c : cleanup_subreg_operands for the alter_subreg call for the following rtx. (insn:HI 9 8 17 /home/ramana/test.c:3 (parallel [ (set (reg:CC_NOOV 24 cc) (compare:CC_NOOV (plus:SI (mult:SI (reg:SI 0 r0 [ x ]) (const_int 4 [0x4])) (reg:SI 1 r1 [ y ])) (const_int 0 [0x0]))) (set (reg/v:SI 0 r0 [orig:133 bytes ] [133]) (plus:SI (cc0) (cc0))) ]) 265 {*arith_shiftsi_compare0} (expr_list:REG_DEAD (reg:SI 1 r1 [ y ]) (nil))) Looking at the dumps this rtx is generated by the rename registers pass in 4.3.x . In trunk however rename registers does not generate this rtx and hence there is no problem. It could still be latent but one has to dig deeper. -- ramana dot r at gmail dot com changed: What|Removed |Added CC||rearnsha at arm dot com, ||ramana dot r at gmail dot ||com http://gcc.gnu.org/bugzilla/show_bug.cgi?id=39076
[Bug target/39076] internal compiler error when cross-compiling flac
--- Comment #3 from s dot neumann at phase-zero dot de 2009-02-03 16:14 --- The code in flac that triggered the problem does also make gcc crash with "-O3 -funroll-loops". I've also tested -O1 and -O2, same problem. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=39076