https://gcc.gnu.org/bugzilla/show_bug.cgi?id=87836
--- Comment #10 from Gary Mills <gary_mills at fastmail dot fm> --- Thanks for the explanation. It's entirely possible that the intermediate gcc was miss-compiled because of excessive optimization. I tried building gcc-7.3.0 with -O1 for 32-bit SPARC only, and got the same ICE. Here's part of build/sparcv7/sparc-sun-solaris2.11/libgcc/config.log: configure:3662: checking for suffix of object files configure:3684: /export/home/mills/Downloads/code/oi-userland/components/developer/gcc-7/build/sparcv7/./gcc/xgcc -B/export/home/mills/Downloads/code/oi-userland/components/developer/gcc-7/build/sparcv7/./gcc/ -B/usr/gcc/7/sparc-sun-solaris2.11/bin/ -B/usr/gcc/7/sparc-sun-solaris2.11/lib/ -isystem /usr/gcc/7/sparc-sun-solaris2.11/include -isystem /usr/gcc/7/sparc-sun-solaris2.11/sys-include -c -O2 -g -O1 conftest.c >&5 conftest.c: In function 'main': conftest.c:11:1: internal compiler error: Segmentation Fault main () ^~~~ 0x68930f crash_signal /export/home/mills/Downloads/code/oi-userland/components/developer/gcc-7/gcc-7.3.0/gcc/toplev.c:337 0x399380 et_splay /export/home/mills/Downloads/code/oi-userland/components/developer/gcc-7/gcc-7.3.0/gcc/et-forest.c:312 0x39a06b et_set_father /export/home/mills/Downloads/code/oi-userland/components/developer/gcc-7/gcc-7.3.0/gcc/et-forest.c:526 0x32f4b7 calculate_dominance_info(cdi_direction) /export/home/mills/Downloads/code/oi-userland/components/developer/gcc-7/gcc-7.3.0/gcc/dominance.c:739 0x6cb28b cleanup_tree_cfg_noloop /export/home/mills/Downloads/code/oi-userland/components/developer/gcc-7/gcc-7.3.0/gcc/tree-cfgcleanup.c:766 0x6cb28b cleanup_tree_cfg() /export/home/mills/Downloads/code/oi-userland/components/developer/gcc-7/gcc-7.3.0/gcc/tree-cfgcleanup.c:883 0x6c58af execute_build_cfg /export/home/mills/Downloads/code/oi-userland/components/developer/gcc-7/gcc-7.3.0/gcc/tree-cfg.c:404 0x6c58af execute /export/home/mills/Downloads/code/oi-userland/components/developer/gcc-7/gcc-7.3.0/gcc/tree-cfg.c:433 Please submit a full bug report, with preprocessed source if appropriate. Please include the complete backtrace with any bug report. See <https://bugs.openindiana.org> for instructions. configure:3688: $? = 1 configure: failed program was: | /* confdefs.h */ | #define PACKAGE_NAME "GNU C Runtime Library" | #define PACKAGE_TARNAME "libgcc" | #define PACKAGE_VERSION "1.0" | #define PACKAGE_STRING "GNU C Runtime Library 1.0" | #define PACKAGE_BUGREPORT "" | #define PACKAGE_URL "http://www.gnu.org/software/libgcc/" | /* end confdefs.h. */ | | int | main () | { | | ; | return 0; | } configure:3702: error: in `/export/home/mills/Downloads/code/oi-userland/components/developer/gcc-7/build/sparcv7/sparc-sun-solaris2.11/libgcc': configure:3705: error: cannot compute suffix of object files: cannot compile I had hoped that a reduction from -O2 to -O1 would be sufficient, but it must not have been. The curious thing was that two copies of xgcc were created during the build: $ find build -name xgcc -ls 23236147 5382 -rwxr-xr-x 1 mills staff 5436884 Nov 11 21:10 build/sparcv7/gcc/xgcc 23217408 4870 -rwxr-xr-x 1 mills staff 4929308 Nov 10 15:19 build/sparcv7/prev-gcc/xgcc I'll try the build again with -O0 to see what happens then.