The gcc.dg/cpp/trad/include.c -fno-show-column compilation test ICEs with... /sw/src/fink.build/gcc44-4.3.999-20081129/darwin_objdir/gcc/xgcc -B/sw/src/fink.build/gcc44-4.3.999-20081129/darwin_objdir/gcc/ /sw/src/fink.build/gcc44-4.3.999-20081129/gcc-4.4-20081129/gcc/testsuite/gcc.dg/cpp/trad/include.c -fno-show-column -traditional-cpp -E -m32 -o include.i <built-in>:0: internal compiler error: Abort trap Please submit a full bug report, with preprocessed source if appropriate. See <http://gcc.gnu.org/bugs.html> for instructions. No luck so far in getting a backtrace. Same error at -m64.
I had the same thing for the PS3 compiler, it turned out due to C++ style comments in the system headers. This was causing libcpp to abort.
I don't see any c++ comments in the included system headers. Is there a way in gcc to dump the preprocessed source in a manner that won't parse out the comments? When I dropped the '-fno-show-column -traditional-cpp' flags, the abort was eliminated but the resulting include.i is missing the comments. A manual search of the system headers didn't show any but it would be nice to be able to verify through gcc.
You can try -C to keep the comments. In the original report you said you can't get a backtrace. That makes it a lot harder :( Could you try shrinking the test case somehow? Or perhaps you could change the abort() calls in libcpp to something that would print __FILE__ and __LINE__. That might help a little.
Here is a reduced testcase: t.c: #include <t.h> --- CUT --- t.h: #ifdef __PME__ #define _TLS_QUAL /*0123456790*/ #endif // __PME__ Compile with "gcc t.c -isystem . -traditional-cpp".
I can reproduce the abort on both i686-linux-gnu and i386-darwin8.11 with my reduced testcase.
The test case from Comment 4 triggers the error on x86_64-apple-darwin10 as well.
This problem in darwin10 is in fact due to c++ comments in /usr/include/Availability.h and /usr/include/AvailabilityInternal.h. Replacing those with c style comments allows the gcc.dg/cpp/trad/include.c -fno-show-column testcase to pass without ICE'ing.
This bug is fixed for the release Mac OS X 10.6 (ie the c++ comments are removed from /usr/include/Availability.h and /usr/include/AvailabilityInternal.h.