I am attempting to build 4.2.3 on HP-UX 11.23/IA. $ bzip2 -dc gcc-4.2.3.tar.bz2 | tar xf - $ mkdir gcc-4.2.3-objdir $ cd gcc-4.2.3-objdir $ /opt/build/china/gcc423/ia64-hp-hpux11.23/bin/as -v GNU assembler version 2.18 (ia64-hp-hpux11.23) using BFD version (GNU Binutils) 2.18 $ CC=cc bash /opt/build/china/gcc-4.2.3/configure --with-included-gettext --enable-shared --with-gnu-as --with-as=/opt/build/china/gcc423/ia64-hp-hpux11.23/bin/as --enable-languages="c" ... $ gmake bootstrap ... /opt/build/china/gcc-4.2.3-objdir/./gcc/xgcc -B/opt/build/china/gcc-4.2.3-objdir/./gcc/ -B/usr/local/ia64-hp-hpux11.23/bin/ -B/usr/local/ia64-hp-hpux11.23/lib/ -isystem /usr/local/ia64-hp-hpux11.23/include -isystem /usr/local/ia64-hp-hpux11.23/sys-include -O2 -O2 -g -DIN_GCC -DUSE_LIBUNWIND_EXCEPTIONS -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition -isystem ./include -g -DIN_LIBGCC2 -D__GCC_FLOAT_NOT_NEEDED -I. -I -I/opt/build/china/gcc-4.2.3/gcc -I/opt/build/china/gcc-4.2.3/gcc/ -I/opt/build/china/gcc-4.2.3/gcc/../include -I./../intl -I/opt/build/china/gcc-4.2.3/gcc/../libcpp/include -I/opt/build/china/gcc-4.2.3/gcc/../libdecnumber -I../libdecnumber -DSHARED -c /opt/build/china/gcc-4.2.3/gcc/config/floatunsitf.c -o libgcc/./floatunsitf_s.o /opt/build/china/gcc-4.2.3/gcc/config/floatunsitf.c:8: warning: no previous prototype for '__floatunsitf' { /usr/ccs/bin/nm -pg libgcc/./__divxf3_s.o libgcc/./__divdf3_s.o libgcc/./__divsf3_s.o libgcc/./__divdi3_s.o libgcc/./__moddi3_s.o libgcc/./__udivdi3_s.o libgcc/./__umoddi3_s.o libgcc/./__divsi3_s.o libgcc/./__modsi3_s.o libgcc/./__udivsi3_s.o libgcc/./__umodsi3_s.o libgcc/./__save_stack_nonlocal_s.o libgcc/./__nonlocal_goto_s.o libgcc/./__restore_stack_nonlocal_s.o libgcc/./__trampoline_s.o libgcc/./_muldi3_s.o libgcc/./_negdi2_s.o libgcc/./_lshrdi3_s.o libgcc/./_ashldi3_s.o libgcc/./_ashrdi3_s.o libgcc/./_cmpdi2_s.o libgcc/./_ucmpdi2_s.o libgcc/./_clear_cache_s.o libgcc/./_enable_execute_stack_s.o libgcc/./_trampoline_s.o libgcc/./__main_s.o libgcc/./_absvsi2_s.o libgcc/./_absvdi2_s.o libgcc/./_addvsi3_s.o libgcc/./_addvdi3_s.o libgcc/./_subvsi3_s.o libgcc/./_subvdi3_s.o libgcc/./_mulvsi3_s.o libgcc/./_mulvdi3_s.o libgcc/./_negvsi2_s.o libgcc/./_negvdi2_s.o libgcc/./_ctors_s.o libgcc/./_ffssi2_s.o libgcc/./_ffsdi2_s.o libgcc/./_clz_s.o libgcc/./_clzsi2_s.o libgcc/./_clzdi2_s.o libgcc/./_ctzsi2_s.o libgcc/./_ctzdi2_s.o libgcc/./_popcount_tab_s.o libgcc/./_popcountsi2_s.o libgcc/./_popcountdi2_s.o libgcc/./_paritysi2_s.o libgcc/./_paritydi2_s.o libgcc/./_powisf2_s.o libgcc/./_powidf2_s.o libgcc/./_powixf2_s.o libgcc/./_powitf2_s.o libgcc/./_mulsc3_s.o libgcc/./_muldc3_s.o libgcc/./_mulxc3_s.o libgcc/./_multc3_s.o libgcc/./_divsc3_s.o libgcc/./_divdc3_s.o libgcc/./_divxc3_s.o libgcc/./_divtc3_s.o libgcc/./_fixunssfsi_s.o libgcc/./_fixunsdfsi_s.o libgcc/./_fixunsxfsi_s.o libgcc/./_fixsfdi_s.o libgcc/./_fixunssfdi_s.o libgcc/./_floatdisf_s.o libgcc/./_floatundisf_s.o libgcc/./_fixdfdi_s.o libgcc/./_fixunsdfdi_s.o libgcc/./_floatdidf_s.o libgcc/./_floatundidf_s.o libgcc/./_fixxfdi_s.o libgcc/./_fixunsxfdi_s.o libgcc/./_floatdixf_s.o libgcc/./_floatundixf_s.o libgcc/./_fixtfdi_s.o libgcc/./_fixunstfdi_s.o libgcc/./_floatditf_s.o libgcc/./_floatunditf_s.o libgcc/./_divdi3_s.o libgcc/./_moddi3_s.o libgcc/./_udivdi3_s.o libgcc/./_umoddi3_s.o libgcc/./_udiv_w_sdiv_s.o libgcc/./_udivmoddi4_s.o libgcc/./quadlib_s.o libgcc/./floatunsitf_s.o; echo %%; \ cat /opt/build/china/gcc-4.2.3/gcc/config/ia64/libgcc-ia64.ver \ | sed -e '/^[ ]*#/d' \ -e 's/^%\(if\|else\|elif\|endif\|define\)/#\1/' \ | /opt/build/china/gcc-4.2.3-objdir/./gcc/xgcc -B/opt/build/china/gcc-4.2.3-objdir/./gcc/ -B/usr/local/ia64-hp-hpux11.23/bin/ -B/usr/local/ia64-hp-hpux11.23/lib/ -isystem /usr/local/ia64-hp-hpux11.23/include -isystem /usr/local/ia64-hp-hpux11.23/sys-include -O2 -O2 -g -DIN_GCC -DUSE_LIBUNWIND_EXCEPTIONS -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition -isystem ./include -g -DIN_LIBGCC2 -D__GCC_FLOAT_NOT_NEEDED -I. -I -I/opt/build/china/gcc-4.2.3/gcc -I/opt/build/china/gcc-4.2.3/gcc/ -I/opt/build/china/gcc-4.2.3/gcc/../include -I./../intl -I/opt/build/china/gcc-4.2.3/gcc/../libcpp/include -I/opt/build/china/gcc-4.2.3/gcc/../libdecnumber -I../libdecnumber -E -xassembler-with-cpp -; \ } | awk -f /opt/build/china/gcc-4.2.3/gcc/mkmap-flat.awk > libgcc/./tmp-libgcc.map Pid 18929 received a SIGSEGV for stack growth failure. Possible causes: insufficient memory or swap space, or stack size exceeded maxssiz. mv 'libgcc/./tmp-libgcc.map' libgcc/./libgcc.map /opt/build/china/gcc-4.2.3-objdir/./gcc/xgcc -B/opt/build/china/gcc-4.2.3-objdir/./gcc/ -B/usr/local/ia64-hp-hpux11.23/bin/ -B/usr/local/ia64-hp-hpux11.23/lib/ -isystem /usr/local/ia64-hp-hpux11.23/include -isystem /usr/local/ia64-hp-hpux11.23/sys-include -O2 -O2 -g -DIN_GCC -DUSE_LIBUNWIND_EXCEPTIONS -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition -isystem ./include -g -DIN_LIBGCC2 -D__GCC_FLOAT_NOT_NEEDED -shared -nodefaultlibs -Wl,+h,libgcc_s.so.0 -o ./libgcc_s.so libgcc/./__divxf3_s.o libgcc/./__divdf3_s.o libgcc/./__divsf3_s.o libgcc/./__divdi3_s.o libgcc/./__moddi3_s.o libgcc/./__udivdi3_s.o libgcc/./__umoddi3_s.o libgcc/./__divsi3_s.o libgcc/./__modsi3_s.o libgcc/./__udivsi3_s.o libgcc/./__umodsi3_s.o libgcc/./__save_stack_nonlocal_s.o libgcc/./__nonlocal_goto_s.o libgcc/./__restore_stack_nonlocal_s.o libgcc/./__trampoline_s.o libgcc/./_muldi3_s.o libgcc/./_negdi2_s.o libgcc/./_lshrdi3_s.o libgcc/./_ashldi3_s.o libgcc/./_ashrdi3_s.o libgcc/./_cmpdi2_s.o libgcc/./_ucmpdi2_s.o libgcc/./_clear_cache_s.o libgcc/./_enable_execute_stack_s.o libgcc/./_trampoline_s.o libgcc/./__main_s.o libgcc/./_absvsi2_s.o libgcc/./_absvdi2_s.o libgcc/./_addvsi3_s.o libgcc/./_addvdi3_s.o libgcc/./_subvsi3_s.o libgcc/./_subvdi3_s.o libgcc/./_mulvsi3_s.o libgcc/./_mulvdi3_s.o libgcc/./_negvsi2_s.o libgcc/./_negvdi2_s.o libgcc/./_ctors_s.o libgcc/./_ffssi2_s.o libgcc/./_ffsdi2_s.o libgcc/./_clz_s.o libgcc/./_clzsi2_s.o libgcc/./_clzdi2_s.o libgcc/./_ctzsi2_s.o libgcc/./_ctzdi2_s.o libgcc/./_popcount_tab_s.o libgcc/./_popcountsi2_s.o libgcc/./_popcountdi2_s.o libgcc/./_paritysi2_s.o libgcc/./_paritydi2_s.o libgcc/./_powisf2_s.o libgcc/./_powidf2_s.o libgcc/./_powixf2_s.o libgcc/./_powitf2_s.o libgcc/./_mulsc3_s.o libgcc/./_muldc3_s.o libgcc/./_mulxc3_s.o libgcc/./_multc3_s.o libgcc/./_divsc3_s.o libgcc/./_divdc3_s.o libgcc/./_divxc3_s.o libgcc/./_divtc3_s.o libgcc/./_fixunssfsi_s.o libgcc/./_fixunsdfsi_s.o libgcc/./_fixunsxfsi_s.o libgcc/./_fixsfdi_s.o libgcc/./_fixunssfdi_s.o libgcc/./_floatdisf_s.o libgcc/./_floatundisf_s.o libgcc/./_fixdfdi_s.o libgcc/./_fixunsdfdi_s.o libgcc/./_floatdidf_s.o libgcc/./_floatundidf_s.o libgcc/./_fixxfdi_s.o libgcc/./_fixunsxfdi_s.o libgcc/./_floatdixf_s.o libgcc/./_floatundixf_s.o libgcc/./_fixtfdi_s.o libgcc/./_fixunstfdi_s.o libgcc/./_floatditf_s.o libgcc/./_floatunditf_s.o libgcc/./_divdi3_s.o libgcc/./_moddi3_s.o libgcc/./_udivdi3_s.o libgcc/./_umoddi3_s.o libgcc/./_udiv_w_sdiv_s.o libgcc/./_udivmoddi4_s.o libgcc/./quadlib_s.o libgcc/./floatunsitf_s.o -lunwind -lc && rm -f ./libgcc_s.so.0 && ln -s libgcc_s.so ./libgcc_s.so.0 /opt/build/china Pid 18942 received a SIGSEGV for stack growth failure. Possible causes: insufficient memory or swap space, or stack size exceeded maxssiz. /gcc-4.2.3-objdir/./gcc/xgcc -B/opt/build/china/gcc-4.2.3-objdir/./gcc/ -B/usr/local/ia64-hp-hpux11.23/bin/ -B/usr/local/ia64-hp-hpux11.23/lib/ -isystem /usr/local/ia64-hp-hpux11.23/include -isystem /usr/local/ia64-hp-hpux11.23/sys-include -O2 -O2 -g -DIN_GCC -DUSE_LIBUNWIND_EXCEPTIONS -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition -isystem ./include -g -DIN_LIBGCC2 -D__GCC_FLOAT_NOT_NEEDED -I. -I -I/opt/build/china/gcc-4.2.3/gcc -I/opt/build/china/gcc-4.2.3/gcc/ -I/opt/build/china/gcc-4.2.3/gcc/../include -I./../intl -I/opt/build/china/gcc-4.2.3/gcc/../libcpp/include -I/opt/build/china/gcc-4.2.3/gcc/../libdecnumber -I../libdecnumber -DSHARED -mlp64 -DL__divxf3 -xassembler-with-cpp -c /opt/build/china/gcc-4.2.3/gcc/config/ia64/lib1funcs.asm -o libgcc/hpux64/__divxf3_s.o gmake[4]: *** [libgcc/hpux64/__divxf3_s.o] Segmentation fault (core dumped) gmake[4]: Leaving directory `/opt/build/china/gcc-4.2.3-objdir/gcc' gmake[3]: *** [stmp-multilib] Error 2 gmake[3]: Leaving directory `/opt/build/china/gcc-4.2.3-objdir/gcc' gmake[2]: *** [all-stage1-gcc] Error 2 gmake[2]: Leaving directory `/opt/build/china/gcc-4.2.3-objdir' gmake[1]: *** [stage1-bubble] Error 2 gmake[1]: Leaving directory `/opt/build/china/gcc-4.2.3-objdir' gmake: *** [bootstrap] Error 2 $ limit cputime unlimited filesize unlimited datasize 1024MB stacksize 128MB coredumpsize 2047MB resident unlimited descriptors 2048 addressspace unlimited cachedthreads 256 aiooperations unlimited aiomemorylocked unlimited RSESTACK 8388608
ld is running at this time so I doubt this is a GCC bug.
(In reply to comment #1) > ld is running at this time so I doubt this is a GCC bug. The Pid it is referring to ("Pid 18929 received a SIGSEGV for stack growth failure.") is /opt/build/china/gcc-4.2.3-objdir/./gcc/xgcc. I ran the command under tusc (similar to truss(1) on Solaris or strace(1) on Redhat) and there is no call to ld.
(In reply to comment #2) > (In reply to comment #1) > > ld is running at this time so I doubt this is a GCC bug. > > The Pid it is referring to ("Pid 18929 received a SIGSEGV for stack growth > failure.") is /opt/build/china/gcc-4.2.3-objdir/./gcc/xgcc. Seems to be recursing in cancel_option until stack runs out: Breakpoint 5, cancel_option (opt_idx=30, next_opt_idx=0, orig_next_opt_idx=555) at /opt/build/gcc-4.2.3/gcc/opts-common.c:118 118 if (cl_options [next_opt_idx].neg_index == opt_idx) (gdb) n 121 if (cl_options [next_opt_idx].neg_index != orig_next_opt_idx) (gdb) 122 return cancel_option (opt_idx, cl_options [next_opt_idx].neg_index, (gdb) Breakpoint 5, cancel_option (opt_idx=30, next_opt_idx=0, orig_next_opt_idx=555) at /opt/build/gcc-4.2.3/gcc/opts-common.c:118 118 if (cl_options [next_opt_idx].neg_index == opt_idx) (gdb) 121 if (cl_options [next_opt_idx].neg_index != orig_next_opt_idx) (gdb) 122 return cancel_option (opt_idx, cl_options [next_opt_idx].neg_index, (gdb) Breakpoint 5, cancel_option (opt_idx=30, next_opt_idx=0, orig_next_opt_idx=555) at /opt/build/gcc-4.2.3/gcc/opts-common.c:118 118 if (cl_options [next_opt_idx].neg_index == opt_idx)
(In reply to comment #3) > (In reply to comment #2) > > (In reply to comment #1) > > > ld is running at this time so I doubt this is a GCC bug. > > > > The Pid it is referring to ("Pid 18929 received a SIGSEGV for stack growth > > failure.") is /opt/build/china/gcc-4.2.3-objdir/./gcc/xgcc. > > > Seems to be recursing in cancel_option until stack runs out: > All due to a bug in awk on ia64-hpux11.23. Using gawk allows the build to complete. Here is a selection of a diff from options.c generated with awk and gawk: { "-W", "This switch is deprecated; use -Wextra instead", - N_OPTS, 1, 0, + N_OPTS, 1, -1, CL_COMMON | CL_REJECT_NEGATIVE, 0, CLVC_BOOLEAN, 0 },
patch at <http://gcc.gnu.org/ml/gcc-patches/2008-03/msg02037.html>
same as PR27794? http://gcc.gnu.org/bugzilla/show_bug.cgi?id=27794 confirmed, gcc 4.2.2 hp ia64 11.23 Possible causes: insufficient memory or swap space, or stack size exceeded maxssiz. make[4]: *** [libgcc/hpux64/__divxf3.o] Segmentation fault (core dumped) make[4]: Leaving directory `/os/build/gcc-4.2.2-build/build/gcc' make[3]: *** [stmp-multilib] Error 2 make[3]: Leaving directory `/os/build/gcc-4.2.2-build/build/gcc' make[2]: *** [all-stage1-gcc] Error 2 make[2]: Leaving directory `/os/build/gcc-4.2.2-build/build' make[1]: *** [stage1-bubble] Error 2 make[1]: Leaving directory `/os/build/gcc-4.2.2-build/build' make: *** [all] Error 2
Subject: Bug 35169 Author: rwild Date: Mon Apr 28 22:27:22 2008 New Revision: 134768 URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=134768 Log: gcc/ PR bootstrap/35169 * optc-gen.awk: Work around HP-UX/IA awk bug. Modified: trunk/gcc/ChangeLog trunk/gcc/optc-gen.awk
Subject: Bug 35169 Author: rwild Date: Fri May 2 04:08:11 2008 New Revision: 134880 URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=134880 Log: gcc/ PR bootstrap/35169 * optc-gen.awk: Work around HP-UX/IA awk bug. Modified: branches/gcc-4_3-branch/gcc/ChangeLog branches/gcc-4_3-branch/gcc/optc-gen.awk
Subject: Bug 35169 Author: rwild Date: Fri May 2 04:15:36 2008 New Revision: 134881 URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=134881 Log: gcc/ PR bootstrap/35169 * optc-gen.awk: Work around HP-UX/IA awk bug. Modified: branches/gcc-4_2-branch/gcc/ChangeLog branches/gcc-4_2-branch/gcc/optc-gen.awk
Fixed.
*** Bug 27794 has been marked as a duplicate of this bug. ***