Created attachment 24698 [details] Preprocessed main.c Target: x86_64-elf Configured with: --target=x86_64-elf --without-headers --enable-languages=c,c++ --disable-nls And then build with: make all-gcc Version: 4.6.1 Command line: x86_64-elf-gcc -m32 -g -nostdlib -nostdinc -fno-builtin -fno-stack-protector -std=gnu99 -Wall -Wextra -pedantic -Wshadow -Wpointer-arith -Wcast-align -Wwrite-strings -Wmissing-prototypes -Wmissing-declarations -Wredundant-decls -Wnested-externs -Winline -Wno-long-long -Wstrict-prototypes -DARCH_X86 -DDEBUG -Iinclude -c src/main.c -o obj/main.o Error message: src/main.c:30:1: internal compiler error: in execute_ipa_pass_list, at passes.c:2426 Please submit a full bug report, with preprocessed source if appropriate. See <http://gcc.gnu.org/bugs.html> for instructions. make: *** [obj/main.o] Error 1 main.i is attached I also tried this with GCC 4.6.0 and 4.5.0. Same error.
Works for me on native x86_64. Also passes.c from 4.6.1 does only have 2052 lines, so your version information cannot be correct.
(In reply to comment #1) > Also passes.c from 4.6.1 does only have 2052 lines, so your version information > cannot be correct. Oh, I'm sorry. You are totally right. I accidentally used a 4.7 snapshot which, obviously, breaks for me in the same manner. Here is the error with a real 4.6.1: x86_64-elf-gcc -m32 -g -nostdlib -nostdinc -fno-builtin -fno-stack-protector -std=gnu99 -Wall -Wextra -pedantic -Wshadow -Wpointer-arith -Wcast-align -Wwrite-strings -Wmissing-prototypes -Wmissing-declarations -Wredundant-decls -Wnested-externs -Winline -Wno-long-long -Wstrict-prototypes -DARCH_X86 -DDEBUG -Iinclude -c src/main.c -o obj/main.o src/main.c:30:1: internal compiler error: in execute_ipa_pass_list, at passes.c:1921 Please submit a full bug report, with preprocessed source if appropriate. See <http://gcc.gnu.org/bugs.html> for instructions. make: *** [obj/main.o] Error 1 Everything else is the same. I just downloaded 4.6.1, build it and executed it and this is result.
I just compiled GCC 4.6.1 again without clang after I found out how to do that. By defining CC = /usr/bin/gcc-4.2 CPP = /usr/bin/cpp-4.2 CXX = /usr/bin/g++-4.2 LD = /usr/bin/gcc-4.2 before the configure step the Apple GCC is used for compilation. If you don't do that, clang will be used on Mac OS with XCode >4 and this leads to this "internal compiler error". So, it doesn't seem to be a GCC issue.
(In reply to andreas from comment #3) > I just compiled GCC 4.6.1 again without clang after I found out how to do > that. > > By defining > CC = /usr/bin/gcc-4.2 > CPP = /usr/bin/cpp-4.2 > CXX = /usr/bin/g++-4.2 > LD = /usr/bin/gcc-4.2 > before the configure step the Apple GCC is used for compilation. > > If you don't do that, clang will be used on Mac OS with XCode >4 and this > leads to this "internal compiler error". > So, it doesn't seem to be a GCC issue. OK, so closing then.