[ Forwarded from http://bugs.debian.org/446714 ] We're seeing the following ICE with 4.2: (sid)1851:tbm@em64t: ~] gcc-4.2 -m32 -c -O dialign-t-prob.c dialign-t-prob.c: In function ‘calc_score_dist’: dialign-t-prob.c:11: warning: incompatible implicit declaration of built-in function ‘pow’ dialign-t-prob.c:13: internal compiler error: in assign_386_stack_local, at config/i386/i386.c:13481 Please submit a full bug report, with preprocessed source if appropriate. The same ICE happened with trunk from 20070916, but no longer happens as of 20071020. I've no idea if this got fixed or became latent.
Created attachment 14630 [details] preprocessed source Shows the problem with gcc 4.2 and with trunk from 20070916 and earlier.
The reduced testcase only shows the problem with 4.2: /* Testcase by Martin Michlmayr <tbm@cyrius.com> */ void calc_score_dist (int mxdlen, long double d, long double **dist) { unsigned long i, scr2; for (i = 1; i <= mxdlen; i++) { for (scr2 = mxdlen; scr2 <= mxdlen + 10; scr2++) { } dist[i][scr2] *= pow(1.0 / d, i); } }
Subject: Bug 34215 Author: uros Date: Mon Nov 26 14:22:59 2007 New Revision: 130439 URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=130439 Log: PR target/34215 * config/i386/i386.md (truncdfsf2): Select SLOT_TEMP stack slot if virtual registers are instantiated. (truncxfsf2): Ditto. (truncxfdf2): Ditto. testsuite/ChangeLog: PR target/34215 * gcc.target/i386/pr34215.c: New test. Added: branches/gcc-4_2-branch/gcc/testsuite/gcc.target/i386/pr34215.c Modified: branches/gcc-4_2-branch/gcc/ChangeLog branches/gcc-4_2-branch/gcc/config/i386/i386.md branches/gcc-4_2-branch/gcc/testsuite/ChangeLog
Fixed for 4.2 branch, latent on mainline.
Subject: Bug 34215 Author: uros Date: Mon Nov 26 15:52:57 2007 New Revision: 130440 URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=130440 Log: PR target/34215 * config/i386/i386.md (truncdfsf2): Select SLOT_TEMP stack slot if virtual registers are instantiated. (truncxf<mode>2): Ditto. (floatsi<mode>2): Ditto. (floatdisf2): Ditto. (floatdidf2): Ditto. testsuite/ChangeLog: PR target/34215 * gcc.target/i386/pr34215.c: New test. Added: trunk/gcc/testsuite/gcc.target/i386/pr34215.c Modified: trunk/gcc/ChangeLog trunk/gcc/config/i386/i386.md trunk/gcc/testsuite/ChangeLog
Fixed.