https://gcc.gnu.org/bugzilla/show_bug.cgi?id=83995
Bug ID: 83995 Summary: ICE: cross compiling for cr16-elf on msys2 Product: gcc Version: 7.2.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: target Assignee: unassigned at gcc dot gnu.org Reporter: gcc at wijen dot net Target Milestone: --- Created attachment 43220 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=43220&action=edit libgcc2.i While cross compiling for cr16-elf in an msys2 environment I came across an ICE. Please note that following exaclty the same procedure does work on arch. During 'make all-target-libgcc': /home/Ben/devel/cr16-elf/gcc-build/./gcc/xgcc -v -save-temps -B/home/Ben/devel/cr16-elf/gcc-build/./gcc/ -B/opt/cr16-elf/cr16-elf/bin/ -B/opt/cr16-elf/cr16-elf/lib/ -isystem /opt/cr16-elf/cr16-elf/include -isystem /opt/cr16-elf/cr16-elf/sys-include -g -O2 -O2 -g -O2 -DIN_GCC -DCROSS_DIRECTORY_STRUCTURE -W -Wall -Wno-narrowing -Wwrite-strings -Wcast-qual -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition -isystem ./include -g -DIN_LIBGCC2 -fbuilding-libgcc -fno-stack-protector -Dinhibit_libc -I. -I. -I../.././gcc -I../../../gcc-7.2.0/libgcc -I../../../gcc-7.2.0/libgcc/. -I../../../gcc-7.2.0/libgcc/../gcc -I../../../gcc-7.2.0/libgcc/../include -DHAVE_CC_TLS -DUSE_EMUTLS -o _mulvdi3.o -MT _mulvdi3.o -MD -MP -MF _mulvdi3.dep -DL_mulvdi3 -c ../../../gcc-7.2.0/libgcc/libgcc2.c -fvisibility=hidden -DHIDE_EXPORTS Reading specs from C:/msys64/home/Ben/devel/cr16-elf/gcc-build/gcc/specs COLLECT_GCC=C:\msys64\home\Ben\devel\cr16-elf\gcc-build\gcc\xgcc.exe Target: cr16-elf Configured with: ../gcc-7.2.0/configure --disable-nls --disable-multilib --disable-shared --disable-threads --prefix=/opt/cr16-elf --target=cr16-elf --with-newlib --enable-languages=c Thread model: single gcc version 7.2.0 (GCC) COLLECT_GCC_OPTIONS='-v' '-save-temps' '-B' 'C:/msys64/home/Ben/devel/cr16-elf/gcc-build/gcc/' '-B' 'C:/msys64/opt/cr16-elf/cr16-elf/bin/' '-B' 'C:/msys64/opt/cr16-elf/cr16-elf/lib/' '-isystem' 'C:/msys64/opt/cr16-elf/cr16-elf/include' '-isystem' 'C:/msys64/opt/cr16-elf/cr16-elf/sys-include' '-g' '-O2' '-O2' '-g' '-O2' '-D' 'IN_GCC' '-D' 'CROSS_DIRECTORY_STRUCTURE' '-Wextra' '-Wall' '-Wno-narrowing' '-Wwrite-strings' '-Wcast-qual' '-Wstrict-prototypes' '-Wmissing-prototypes' '-Wold-style-definition' '-isystem' './include' '-g' '-D' 'IN_LIBGCC2' '-fbuilding-libgcc' '-fno-stack-protector' '-D' 'inhibit_libc' '-I' '.' '-I' '.' '-I' '../.././gcc' '-I' '../../../gcc-7.2.0/libgcc' '-I' '../../../gcc-7.2.0/libgcc/.' '-I' '../../../gcc-7.2.0/libgcc/../gcc' '-I' '../../../gcc-7.2.0/libgcc/../include' '-D' 'HAVE_CC_TLS' '-D' 'USE_EMUTLS' '-o' '_mulvdi3.o' '-MT' '_mulvdi3.o' '-MD' '-MP' '-MF' '_mulvdi3.dep' '-D' 'L_mulvdi3' '-c' '-fvisibility=hidden' '-D' 'HIDE_EXPORTS' C:/msys64/home/Ben/devel/cr16-elf/gcc-build/gcc/cc1.exe -E -quiet -v -I . -I . -I ../.././gcc -I ../../../gcc-7.2.0/libgcc -I ../../../gcc-7.2.0/libgcc/. -I ../../../gcc-7.2.0/libgcc/../gcc -I ../../../gcc-7.2.0/libgcc/../include -iprefix c:\msys64\home\ben\devel\cr16-elf\gcc-build\gcc\../lib/gcc/cr16-elf/7.2.0/ -isystem C:/msys64/home/Ben/devel/cr16-elf/gcc-build/gcc/include -isystem C:/msys64/home/Ben/devel/cr16-elf/gcc-build/gcc/include-fixed -MD _mulvdi3.d -MF _mulvdi3.dep -MP -MT _mulvdi3.o -D IN_GCC -D CROSS_DIRECTORY_STRUCTURE -D IN_LIBGCC2 -D inhibit_libc -D HAVE_CC_TLS -D USE_EMUTLS -D L_mulvdi3 -D HIDE_EXPORTS -isystem C:/msys64/opt/cr16-elf/cr16-elf/include -isystem C:/msys64/opt/cr16-elf/cr16-elf/sys-include -isystem ./include ../../../gcc-7.2.0/libgcc/libgcc2.c -Wextra -Wall -Wno-narrowing -Wwrite-strings -Wcast-qual -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition -fbuilding-libgcc -fno-stack-protector -fvisibility=hidden -g -g -g -fworking-directory -O2 -O2 -O2 -fpch-preprocess -o libgcc2.i ignoring nonexistent directory "C:/msys64/opt/cr16-elf/cr16-elf/include" ignoring nonexistent directory "C:/msys64/opt/cr16-elf/cr16-elf/sys-include" ignoring nonexistent directory "./include" ignoring nonexistent directory "c:\msys64\home\ben\devel\cr16-elf\gcc-build\gcc\../lib/gcc/cr16-elf/7.2.0/include" ignoring nonexistent directory "c:\msys64\home\ben\devel\cr16-elf\gcc-build\gcc\../lib/gcc/cr16-elf/7.2.0/include-fixed" ignoring nonexistent directory "c:\msys64\home\ben\devel\cr16-elf\gcc-build\gcc\../lib/gcc/cr16-elf/7.2.0/../../../../cr16-elf/sys-include" ignoring nonexistent directory "c:\msys64\home\ben\devel\cr16-elf\gcc-build\gcc\../lib/gcc/cr16-elf/7.2.0/../../../../cr16-elf/include" ignoring nonexistent directory "c:/msys64/home/ben/devel/cr16-elf/gcc-build/lib/gcc/cr16-elf/7.2.0/include" ignoring nonexistent directory "c:/msys64/home/ben/devel/cr16-elf/gcc-build/lib/gcc/cr16-elf/7.2.0/include-fixed" ignoring nonexistent directory "c:/msys64/home/ben/devel/cr16-elf/gcc-build/cr16-elf/sys-include" ignoring nonexistent directory "c:/msys64/home/ben/devel/cr16-elf/gcc-build/cr16-elf/include" ignoring duplicate directory "." ignoring duplicate directory "../../../gcc-7.2.0/libgcc/." #include "..." search starts here: #include <...> search starts here: . ../.././gcc ../../../gcc-7.2.0/libgcc ../../../gcc-7.2.0/libgcc/../gcc ../../../gcc-7.2.0/libgcc/../include C:/msys64/home/Ben/devel/cr16-elf/gcc-build/gcc/include C:/msys64/home/Ben/devel/cr16-elf/gcc-build/gcc/include-fixed End of search list. COLLECT_GCC_OPTIONS='-v' '-save-temps' '-B' 'C:/msys64/home/Ben/devel/cr16-elf/gcc-build/gcc/' '-B' 'C:/msys64/opt/cr16-elf/cr16-elf/bin/' '-B' 'C:/msys64/opt/cr16-elf/cr16-elf/lib/' '-isystem' 'C:/msys64/opt/cr16-elf/cr16-elf/include' '-isystem' 'C:/msys64/opt/cr16-elf/cr16-elf/sys-include' '-g' '-O2' '-O2' '-g' '-O2' '-D' 'IN_GCC' '-D' 'CROSS_DIRECTORY_STRUCTURE' '-Wextra' '-Wall' '-Wno-narrowing' '-Wwrite-strings' '-Wcast-qual' '-Wstrict-prototypes' '-Wmissing-prototypes' '-Wold-style-definition' '-isystem' './include' '-g' '-D' 'IN_LIBGCC2' '-fbuilding-libgcc' '-fno-stack-protector' '-D' 'inhibit_libc' '-I' '.' '-I' '.' '-I' '../.././gcc' '-I' '../../../gcc-7.2.0/libgcc' '-I' '../../../gcc-7.2.0/libgcc/.' '-I' '../../../gcc-7.2.0/libgcc/../gcc' '-I' '../../../gcc-7.2.0/libgcc/../include' '-D' 'HAVE_CC_TLS' '-D' 'USE_EMUTLS' '-o' '_mulvdi3.o' '-MT' '_mulvdi3.o' '-MD' '-MP' '-MF' '_mulvdi3.dep' '-D' 'L_mulvdi3' '-c' '-fvisibility=hidden' '-D' 'HIDE_EXPORTS' C:/msys64/home/Ben/devel/cr16-elf/gcc-build/gcc/cc1.exe -fpreprocessed libgcc2.i -quiet -dumpbase libgcc2.c -auxbase-strip _mulvdi3.o -g -g -g -O2 -O2 -O2 -Wextra -Wall -Wno-narrowing -Wwrite-strings -Wcast-qual -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition -version -fbuilding-libgcc -fno-stack-protector -fvisibility=hidden -o libgcc2.s GNU C11 (GCC) version 7.2.0 (cr16-elf) compiled by GNU C version 7.2.0, GMP version 6.1.2, MPFR version 3.1.6, MPC version 1.0.3, isl version isl-0.18-GMP GGC heuristics: --param ggc-min-expand=100 --param ggc-min-heapsize=131072 GNU C11 (GCC) version 7.2.0 (cr16-elf) compiled by GNU C version 7.2.0, GMP version 6.1.2, MPFR version 3.1.6, MPC version 1.0.3, isl version isl-0.18-GMP GGC heuristics: --param ggc-min-expand=100 --param ggc-min-heapsize=131072 Compiler executable checksum: b4681e7a16282abe83bff1d866237837 ../../../gcc-7.2.0/libgcc/libgcc2.c: In function '__mulvdi3': ../../../gcc-7.2.0/libgcc/libgcc2.c:395:1: error: unrecognizable insn: } ^ (insn/f 533 532 534 2 (set (reg/f:SI 15 sp) (plus:SI (reg/f:SI 15 sp) (const_int 4294967264 [0xffffffe0]))) "../../../gcc-7.2.0/libgcc/libgcc2.c":277 -1 (nil)) ../../../gcc-7.2.0/libgcc/libgcc2.c:395:1: internal compiler error: in extract_insn, at recog.c:2311 libbacktrace could not find executable to open Please submit a full bug report, with preprocessed source if appropriate. See <https://gcc.gnu.org/bugs/> for instructions.