libtool: compile: gcc -v -save-temps -DHAVE_CONFIG_H -I. -I../.. -I../.. -I../../lib/common -I../../lib/gvc -I../../lib/pack -I../../lib/ortho -I../../lib/pathplan -I../../lib/graph -I../../lib/sparse -I../../lib/rbtree -I../../lib/sfdpgen -I../../lib/cdt -Os -Wall -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -Wno-unknown-pragmas -Wstrict-prototypes -Wpointer-arith -Wall -ffast-math -MT stress.lo -MD -MP -MF .deps/stress.Tpo -c stress.c -fPIC -DPIC -o .libs/stress.o Using built-in specs. COLLECT_GCC=gcc COLLECT_LTO_WRAPPER=/usr/lib/gcc/i586-pc-linux-gnu/4.5.0/lto-wrapper Target: i586-pc-linux-gnu Configured with: ..//configure --prefix=/usr --libexecdir=/usr/lib --enable-shared --with-system-zlib --enable-languages=c,c++,objc,java,ada,fortran --enable-threads --enable-__cxa_atexit --enable-clocale=gnu --enable-libada --enable-shared --with-ecj-jar=/usr/share/java/ecj.jar i586-pc-linux-gnu Thread model: posix gcc version 4.5.0 (GCC) ... COLLECT_GCC_OPTIONS='-v' '-save-temps' '-DHAVE_CONFIG_H' '-I.' '-I../..' '-I../..' '-I../../lib/common' '-I../../lib/gvc' '-I../../lib/pack' '-I../../lib/ortho' '-I../../lib/pathplan' '-I../../lib/graph' '-I../../lib/sparse' '-I../../lib/rbtree' '-I../../lib/sfdpgen' '-I../../lib/cdt' '-Os' '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' '-Wno-unknown-pragmas' '-Wstrict-prototypes' '-Wpointer-arith' '-Wall' '-ffast-math' '-MT' 'stress.lo' '-MD' '-MP' '-MF' '.deps/stress.Tpo' '-c' '-fPIC' '-DPIC' '-o' '.libs/stress.o' '-mtune=pentium' '-march=pentium' /usr/lib/gcc/i586-pc-linux-gnu/4.5.0/cc1 -fpreprocessed stress.i -quiet -dumpbase stress.c -mtune=pentium -march=pentium -auxbase-strip .libs/stress.o -Os -Wno-unknown-pragmas -Wstrict-prototypes -Wpointer-arith -Wall -version -ffast-math -fPIC -o stress.s GNU C (GCC) version 4.5.0 (i586-pc-linux-gnu) compiled by GNU C version 4.5.0, GMP version 5.0.1, MPFR version 2.4.2, MPC version 0.8.1 GGC heuristics: --param ggc-min-expand=98 --param ggc-min-heapsize=127922 GNU C (GCC) version 4.5.0 (i586-pc-linux-gnu) compiled by GNU C version 4.5.0, GMP version 5.0.1, MPFR version 2.4.2, MPC version 0.8.1 GGC heuristics: --param ggc-min-expand=98 --param ggc-min-heapsize=127922 Compiler executable checksum: 7fe8daf58b4922cb9313351112738768 stress.c: In function �<80><98>mdsModel�<80><99>: stress.c:1373:12: warning: �<80><98>delta�<80><99> may be used uninitialized in this function stress.c: In function �<80><98>compute_apsp_artifical_weights_packed�<80><99>: stress.c:1494:1: error: unrecognizable insn: (jump_insn 445 444 315 11 stress.c:1454 (set (pc) (if_then_else (lt (reg:CCFP 17 flags) (const_int 0 [0x0])) (label_ref:SI 303) (pc))) -1 (expr_list:REG_BR_PROB (const_int 2900 [0xb54]) (nil)) -> 303) stress.c:1494:1: internal compiler error: in extract_insn, at recog.c:2103 Please submit a full bug report, with preprocessed source if appropriate. See <http://gcc.gnu.org/bugs.html> for instructions.
Created attachment 20918 [details] Original preprocessed source
Created attachment 20919 [details] Original compilation log with -v
/* minimal source showing (hopefully) the same ICE */ typedef struct { float *ewgts; } vtx_data; extern int whatever(vtx_data *); float *compute_apsp_artifical_weights_packed (vtx_data * graph, int n) { float *weights; weights = (float *) zmalloc (n * sizeof (float)); weights[n] = whatever(graph) > graph[n].ewgts[n] ? whatever(graph) : graph[n].ewgts[n]; } /* gcc -v -save-temps -Os -ffast-math ffmos.c */ Using built-in specs. COLLECT_GCC=gcc COLLECT_LTO_WRAPPER=/usr/lib/gcc/i586-pc-linux-gnu/4.5.0/lto-wrapper Target: i586-pc-linux-gnu Configured with: ..//configure --prefix=/usr --libexecdir=/usr/lib --enable-shared --with-system-zlib --enable-languages=c,c++,objc,java,ada,fortran --enable-threads --enable-__cxa_atexit --enable-clocale=gnu --enable-libada --enable-shared --with-ecj-jar=/usr/share/java/ecj.jar i586-pc-linux-gnu Thread model: posix gcc version 4.5.0 (GCC) COLLECT_GCC_OPTIONS='-v' '-save-temps' '-Os' '-ffast-math' '-c' '-mtune=pentium' '-march=pentium' /usr/lib/gcc/i586-pc-linux-gnu/4.5.0/cc1 -E -quiet -v ffmos.c -mtune=pentium -march=pentium -ffast-math -Os -fpch-preprocess -o ffmos.i ignoring nonexistent directory "/usr/local/include" ignoring nonexistent directory "/usr/lib/gcc/i586-pc-linux-gnu/4.5.0/../../../../i586-pc-linux-gnu/include" #include "..." search starts here: #include <...> search starts here: /usr/lib/gcc/i586-pc-linux-gnu/4.5.0/include /usr/lib/gcc/i586-pc-linux-gnu/4.5.0/include-fixed /usr/include End of search list. COLLECT_GCC_OPTIONS='-v' '-save-temps' '-Os' '-ffast-math' '-c' '-mtune=pentium' '-march=pentium' /usr/lib/gcc/i586-pc-linux-gnu/4.5.0/cc1 -fpreprocessed ffmos.i -quiet -dumpbase ffmos.c -mtune=pentium -march=pentium -auxbase ffmos -Os -version -ffast-math -o ffmos.s GNU C (GCC) version 4.5.0 (i586-pc-linux-gnu) compiled by GNU C version 4.5.0, GMP version 5.0.1, MPFR version 2.4.2, MPC version 0.8.1 GGC heuristics: --param ggc-min-expand=98 --param ggc-min-heapsize=127922 GNU C (GCC) version 4.5.0 (i586-pc-linux-gnu) compiled by GNU C version 4.5.0, GMP version 5.0.1, MPFR version 2.4.2, MPC version 0.8.1 GGC heuristics: --param ggc-min-expand=98 --param ggc-min-heapsize=127922 Compiler executable checksum: 7fe8daf58b4922cb9313351112738768 ffmos.c: In function ‘compute_apsp_artifical_weights_packed’: ffmos.c:12:1: error: unrecognizable insn: (jump_insn 59 58 47 2 ffmos.c:11 (set (pc) (if_then_else (lt (reg:CCFP 17 flags) (const_int 0 [0x0])) (label_ref:SI 45) (pc))) -1 (expr_list:REG_BR_PROB (const_int 2071 [0x817]) (nil)) -> 45) ffmos.c:12:1: internal compiler error: in extract_insn, at recog.c:2103 Please submit a full bug report, with preprocessed source if appropriate. See <http://gcc.gnu.org/bugs.html> for instructions.
It is caused by revision 149035: http://gcc.gnu.org/bugzilla/show_bug.cgi?id=44546
Confirmed. bbro pass is blindly changing: (jump_insn 55 57 23 2 pr44546.c:10 (set (pc) (if_then_else (unle (reg:CCFP 17 flags) (const_int 0 [0])) (label_ref:SI 28) (pc))) 576 {*jcc_1} (expr_list:REG_DEAD (reg:CCFP 17 flags) (expr_list:REG_BR_PROB (const_int 7929 [0x1ef9]) (nil))) to (jump_insn 55 57 28 2 pr44546.c:10 (set (pc) (if_then_else (gt (reg:CCFP 17 flags) (const_int 0 [0])) (label_ref:SI 89) (pc))) 576 {*jcc_1} (expr_list:REG_DEAD (reg:CCFP 17 flags) (expr_list:REG_BR_PROB (const_int 2071 [0x817]) (nil))) This is not valid insn, since GT condition does not satisfy ix86_trivial_fp_comparison_operator predicate.
(In reply to comment #5) > bbro pass is blindly changing: Ooops, scrap this. Post-reload splitter is splitting in a wrong way.
Created attachment 20946 [details] Proposed patch Patch in testing.
Patch at http://gcc.gnu.org/ml/gcc-patches/2010-06/msg01973.html
Subject: Bug 44546 Author: uros Date: Sun Jun 20 21:42:10 2010 New Revision: 161055 URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=161055 Log: PR target/44546 * config/i386/predicates.md (ix86_swapped_fp_comparsion_operator): New predicate. * config/i386/i386.md (*fp_jcc_8<mode>_387): Use ix86_swapped_fp_comparsion_operator instead of ix86_fp_comparison_operator. (*fp_jcc_1_387): Rename from *fp_jcc_3_387. (*fp_jcc_1r_387): Rename from *fp_jcc_4_387. (*fp_jcc_2_387): Rename from *fp_jcc_5_387. (*fp_jcc_2r_387): Rename from *fp_jcc_6_387. (*fp_jcc_3_387): Rename from *fp_jcc_7_387. (*fp_jcc_4_<mode>_387): Rename from *fp_jcc_8<mode>_387. testsuite/ChangeLog: PR target/44546 * gcc.target/i386/pr44546.c: New test. Added: trunk/gcc/testsuite/gcc.target/i386/pr44546.c Modified: trunk/gcc/ChangeLog trunk/gcc/config/i386/i386.md trunk/gcc/config/i386/predicates.md trunk/gcc/testsuite/ChangeLog
Subject: Bug 44546 Author: uros Date: Mon Jun 21 14:52:07 2010 New Revision: 161085 URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=161085 Log: PR target/44546 * config/i386/predicates.md (ix86_swapped_fp_comparsion_operator): New predicate. * config/i386/i386.md (*fp_jcc_8<mode>_387 and splitters): Use ix86_swapped_fp_comparsion_operator instead of ix86_fp_comparison_operator. (*fp_jcc_1_387): Rename from *fp_jcc_3_387. (*fp_jcc_1r_387): Rename from *fp_jcc_4_387. (*fp_jcc_2_387): Rename from *fp_jcc_5_387. (*fp_jcc_2r_387): Rename from *fp_jcc_6_387. (*fp_jcc_3_387): Rename from *fp_jcc_7_387. (*fp_jcc_4_<mode>_387): Rename from *fp_jcc_8<mode>_387. testsuite/ChangeLog: PR target/44546 * gcc.target/i386/pr44546.c: New test. Added: branches/gcc-4_5-branch/gcc/testsuite/gcc.target/i386/pr44546.c Modified: branches/gcc-4_5-branch/gcc/ChangeLog branches/gcc-4_5-branch/gcc/config/i386/i386.md branches/gcc-4_5-branch/gcc/config/i386/predicates.md branches/gcc-4_5-branch/gcc/testsuite/ChangeLog
Fixed.
*** Bug 44700 has been marked as a duplicate of this bug. ***