From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 30786 invoked by alias); 23 Oct 2012 23:28:32 -0000 Received: (qmail 30732 invoked by uid 48); 23 Oct 2012 23:28:18 -0000 From: "danglin at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug middle-end/55046] New: [4.8 Regression] ICE in ira_reuse_stack_slot at ira-color.c:4065 Date: Tue, 23 Oct 2012 23:28:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: middle-end X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: danglin at gcc dot gnu.org X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Changed-Fields: Message-ID: X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated Content-Type: text/plain; charset="UTF-8" MIME-Version: 1.0 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org X-SW-Source: 2012-10/txt/msg02134.txt.bz2 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55046 Bug #: 55046 Summary: [4.8 Regression] ICE in ira_reuse_stack_slot at ira-color.c:4065 Classification: Unclassified Product: gcc Version: 4.8.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: middle-end AssignedTo: unassigned@gcc.gnu.org ReportedBy: danglin@gcc.gnu.org Host: hppa2.0w-hp-hpux11.11 Target: hppa2.0w-hp-hpux11.11 Build: hppa2.0w-hp-hpux11.11 Created attachment 28516 --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=28516 Preprocessed source The ICE breaks building the fortran library as follows: /opt/gnu/bin/bash ./libtool --tag=FC --mode=compile /test/gnu/gcc/objdir/./gc c/gfortran -B/test/gnu/gcc/objdir/./gcc/ -B/opt/gnu/gcc/gcc-4.8/hppa2.0w-hp-hpux11.11/bin/ -B/opt/gnu/gcc/gcc-4.8/hppa2.0w-hp-hpux11.11/lib/ -isystem /opt/gnu/g cc/gcc-4.8/hppa2.0w-hp-hpux11.11/include -isystem /opt/gnu/gcc/gcc-4.8/hppa2.0w- hp-hpux11.11/sys-include -DHAVE_CONFIG_H -I. -I../../../gcc/libgfortran -iqu ote../../../gcc/libgfortran/io -I../../../gcc/libgfortran/../gcc -I../../../gcc/libgfortran/../gcc/config -I../../../gcc/libgfortran/../libquadmath -I../.././gcc -I../../../gcc/libgfortran/../libgcc -I../libgcc -I . -Wall -Werror -fimplicit-none -fno-repack-arrays -fno-underscoring -fallow-leading-underscore -g -O2 -c -o _dim_r16.lo `test -f '../../../gcc/libgfortran/generated/_dim_r16.F90' || ec ho '../../../gcc/libgfortran/'`../../../gcc/libgfortran/generated/_dim_r16.F90libtool: compile: /test/gnu/gcc/objdir/./gcc/gfortran -B/test/gnu/gcc/objdir/./gcc/ -B/opt/gnu/gcc/gcc-4.8/hppa2.0w-hp-hpux11.11/bin/ -B/opt/gnu/gcc/gcc-4.8/hppa2.0w-hp-hpux11.11/lib/ -isystem /opt/gnu/gcc/gcc-4.8/hppa2.0w-hp-hpux11.11/include -isystem /opt/gnu/gcc/gcc-4.8/hppa2.0w-hp-hpux11.11/sys-include -DHAVE_CONF IG_H -I. -I../../../gcc/libgfortran -iquote../../../gcc/libgfortran/io -I../../../gcc/libgfortran/../gcc -I../../../gcc/libgfortran/../gcc/config -I../../../gcc/libgfortran/../libquadmath -I../.././gcc -I../../../gcc/libgfortran/../libgcc -I../libgcc -I . -Wall -Werror -fimplicit-none -fno-repack-arrays -fno-underscoring -fallow-leading-underscore -g -O2 -c ../../../gcc/libgfortran/generated/_dim_ r16.F90 -fPIC -o .libs/_dim_r16.o ../../../gcc/libgfortran/generated/_dim_r16.F90: In function '_gfortran_specific__dim_r16': ../../../gcc/libgfortran/generated/_dim_r16.F90:42:0: internal compiler error: Segmentation fault end function ^ ../../../gcc/libgfortran/generated/_dim_r16.F90:42:0: internal compiler error: Aborted gfortran: internal compiler error: Aborted (program f951) ./libtool: line 1156: 11697 ABORT instruction (core dumped) /test/gnu/gcc/objdir/./gcc/gfortran -B/test/gnu/gcc/objdir/./gcc/ -B/opt/gnu/gcc/gcc-4.8/hppa2.0w-hp-hpux11.11/bin/ -B/opt/gnu/gcc/gcc-4.8/hppa2.0w-hp-hpux11.11/lib/ -isystem /opt/gnu/gcc/gcc-4.8/hppa2.0w-hp-hpux11.11/include -isystem /opt/gnu/gcc/gcc-4.8/hppa2.0w-hp-hpux11.11/sys-include -DHAVE_CONFIG_H -I. -I../../../gcc/libgfortran -iquote../../../gcc/libgfortran/io -I../../../gcc/libgfortran/../gcc -I../../../gcc/libgfortran/../gcc/config -I../../../gcc/libgfortran/../libquadmath -I../.././gcc -I../../../gcc/libgfortran/../libgcc -I../libgcc -I . -Wall -Werror -fimplicit-none -fno-repack-arrays -fno-underscoring -fallow-leading-underscore -g -O2 -c ../../../gcc/libgfortran/generated/_dim_r16.F90 -fPIC -o .libs/_dim_r16.o make[3]: *** [_dim_r16.lo] Error 1 -bash-3.2$ ./xgcc -B./ -v Reading specs from ./specs COLLECT_GCC=./xgcc COLLECT_LTO_WRAPPER=./lto-wrapper Target: hppa2.0w-hp-hpux11.11 Configured with: ../gcc/configure --with-gnu-as --with-as=/opt/gnu/bin/as --enable-shared --with-local-prefix=/opt/gnu --prefix=/opt/gnu/gcc/gcc-4.8 --with-gmp=/opt/gnu/gcc/gmp --enable-threads=posix --enable-debug=no --disable-nls --without-cloog --without-ppl --enable-languages=c,c++,objc,fortran,java,ada,obj-c++ Thread model: posix gcc version 4.8.0 20121023 (experimental) [trunk revision 192710] (GCC) (gdb) r Starting program: /test/gnu/gcc/objdir/gcc/f951 ../../../gcc/libgfortran/generated/_dim_r16.F90 -cpp=_dim_r16.f90 -quiet -v -I . -I ../../../gcc/libgfortran -I ../../../gcc/libgfortran/../gcc -I ../../../gcc/libgfortran/../gcc/config -I ../../../gcc/libgfortran/../libquadmath -I ../.././gcc -I ../../../gcc/libgfortran/../libgcc -I ../libgcc -I . -iprefix /test/gnu/gcc/objdir/gcc/../lib/gcc/hppa2.0w-hp-hpux11.11/4.8.0/ -isystem /test/gnu/gcc/objdir/./gcc/include -isystem /test/gnu/gcc/objdir/./gcc/include-fixed -D HAVE_CONFIG_H -isystem /opt/gnu/gcc/gcc-4.8/hppa2.0w-hp-hpux11.11/include -isystem /opt/gnu/gcc/gcc-4.8/hppa2.0w-hp-hpux11.11/sys-include -iquote ../../../gcc/libgfortran/io ../../../gcc/libgfortran/generated/_dim_r16.F90 -quiet -dumpbase _dim_r16.F90 -auxbase-strip .libs/_dim_r16.o -g -O2 -Wall -Werror -version -fimplicit-none -fno-repack-arrays -fno-underscoring -fallow-leading-underscore -fPIC -fintrinsic-modules-path finclude -o _dim_r16.s warning: Private mapping of shared library text was not specified by the executable; setting a breakpoint in a shared library which is not privately mapped will not work. See the HP-UX 11i v3 chatr manpage for methods to privately map shared library text. GNU Fortran (GCC) version 4.8.0 20121023 (experimental) [trunk revision 192710] (hppa2.0w-hp-hpux11.11) compiled by GNU C version 4.8.0 20121023 (experimental) [trunk revision 192710], GMP version 5.0.2, MPFR version 3.1.0-p1, MPC version 1.0 warning: MPFR header version 3.1.0-p1 differs from library version 3.0.1-p4. GGC heuristics: --param ggc-min-expand=30 --param ggc-min-heapsize=4096 ignoring nonexistent directory "/test/gnu/gcc/objdir/gcc/../lib/gcc/hppa2.0w-hp-hpux11.11/4.8.0/include" ignoring nonexistent directory "/test/gnu/gcc/objdir/gcc/../lib/gcc/hppa2.0w-hp-hpux11.11/4.8.0/include-fixed" ignoring nonexistent directory "/test/gnu/gcc/objdir/gcc/../lib/gcc/hppa2.0w-hp-hpux11.11/4.8.0/../../../../hppa2.0w-hp-hpux11.11/include" ignoring nonexistent directory "/opt/gnu/gcc/gcc-4.8/lib/gcc/hppa2.0w-hp-hpux11.11/4.8.0/include" ignoring nonexistent directory "/opt/gnu/gcc/gcc-4.8/include" ignoring nonexistent directory "/opt/gnu/gcc/gcc-4.8/lib/gcc/hppa2.0w-hp-hpux11.11/4.8.0/include-fixed" ignoring nonexistent directory "/opt/gnu/gcc/gcc-4.8/hppa2.0w-hp-hpux11.11/include" ignoring duplicate directory "." ignoring nonexistent directory "/opt/gnu/gcc/gcc-4.8/hppa2.0w-hp-hpux11.11/include" ignoring nonexistent directory "/opt/gnu/gcc/gcc-4.8/hppa2.0w-hp-hpux11.11/sys-include" #include "..." search starts here: #include <...> search starts here: . ../../../gcc/libgfortran ../../../gcc/libgfortran/../gcc ../../../gcc/libgfortran/../gcc/config ../../../gcc/libgfortran/../libquadmath ../.././gcc ../../../gcc/libgfortran/../libgcc ../libgcc /test/gnu/gcc/objdir/./gcc/include /test/gnu/gcc/objdir/./gcc/include-fixed ../../../gcc/libgfortran/io /opt/gnu/include /usr/include End of search list. GNU Fortran (GCC) version 4.8.0 20121023 (experimental) [trunk revision 192710] (hppa2.0w-hp-hpux11.11) compiled by GNU C version 4.8.0 20121023 (experimental) [trunk revision 192710], GMP version 5.0.2, MPFR version 3.1.0-p1, MPC version 1.0 warning: MPFR header version 3.1.0-p1 differs from library version 3.0.1-p4. GGC heuristics: --param ggc-min-expand=30 --param ggc-min-heapsize=4096 Program received signal SIGSEGV, Segmentation fault. 0x004daff4 in _Z20ira_reuse_stack_slotijj (regno=102, inherent_size=4, total_size=4) at ../../gcc/gcc/ira-color.c:4065 4065 ira_assert (inherent_size == PSEUDO_REGNO_BYTES (regno) (gdb) bt #0 0x004daff4 in _Z20ira_reuse_stack_slotijj (regno=102, inherent_size=4, total_size=4) at ../../gcc/gcc/ira-color.c:4065 #1 0x005b1808 in _ZL9alter_regiib (i=102, from_reg=-1, dont_share_p=false) at ../../gcc/gcc/reload1.c:2205 #2 0x005b9b40 in _Z6reloadP7rtx_defi ( first=0x40116b60 , global=1074854752) at ../../gcc/gcc/reload1.c:793 #3 0x004be268 in _ZL21rest_of_handle_reloadv () at ../../gcc/gcc/ira.c:4355 #4 0x0055c660 in _Z16execute_one_passP8opt_pass ( pass=0x4005e428 ) at ../../gcc/gcc/passes.c:2320 #5 0x0055cad0 in _Z17execute_pass_listP8opt_pass ( pass=0x4005e428 ) at ../../gcc/gcc/passes.c:2381 #6 0x0055cae8 in _Z17execute_pass_listP8opt_pass ( pass=0x400687bc ) at ../../gcc/gcc/passes.c:2382 #7 0x002662e4 in _ZL15expand_functionP11cgraph_node (node=0x7ae78000) at ../../gcc/gcc/cgraphunit.c:1601 #8 0x00268600 in _Z7compilev () at ../../gcc/gcc/cgraphunit.c:1705 #9 0x00268e94 in _Z25finalize_compilation_unitv () at ../../gcc/gcc/cgraphunit.c:2080 #10 0x004ec1a8 in _Z25write_global_declarationsv () at ../../gcc/gcc/langhooks.c:323 #11 0x00111ac4 in _ZL29gfc_write_global_declarationsv () at ../../gcc/gcc/fortran/f95-lang.c:265 ---Type to continue, or q to quit--- #12 0x00633c88 in compile_file() () at ../../gcc/gcc/toplev.c:560 #13 0x00635d84 in _Z11toplev_mainiPPc (argc=0, argv=0x0) at ../../gcc/gcc/toplev.c:1866 #14 0x00921428 in main (argc=102, argv=0x4) at ../../gcc/gcc/main.c:36 (gdb) p regno $1 = 102 (gdb) list 4060 ira_allocno_t another_allocno, allocno = ira_regno_allocno_map[regno]; 4061 rtx x; 4062 bitmap_iterator bi; 4063 struct ira_spilled_reg_stack_slot *slot = NULL; 4064 4065 ira_assert (inherent_size == PSEUDO_REGNO_BYTES (regno) 4066 && inherent_size <= total_size 4067 && ALLOCNO_HARD_REGNO (allocno) < 0); 4068 if (! flag_ira_share_spill_slots) 4069 return NULL_RTX; (gdb) p allocno $2 = (ira_allocno_t) 0x0 (gdb) disass $pc-16,$pc+16 Dump of assembler code from 0x4dafe4 to 0x4db004: 0x004dafe4 <_Z20ira_reuse_stack_slotijj+124>: ldb 0(ret0),r14 0x004dafe8 <_Z20ira_reuse_stack_slotijj+128>: cmpb,<> r25,r14,0x4db594 <_Z20ira_reuse_stack_slotijj+1580> 0x004dafec <_Z20ira_reuse_stack_slotijj+132>: depw,z r26,29,30,r7 0x004daff0 <_Z20ira_reuse_stack_slotijj+136>: cmpb,<<,n r24,r14,0x4db594 <_Z20ira_reuse_stack_slotijj+1580> => 0x004daff4 <_Z20ira_reuse_stack_slotijj+140>: ldh c(r4),r13 0x004daff8 <_Z20ira_reuse_stack_slotijj+144>: extrw,s r13,31,16,r13 0x004daffc <_Z20ira_reuse_stack_slotijj+148>: cmpib,<= 0,r13,0x4db594 <_Z20ira_reuse_stack_slotijj+1580> 0x004db000 <_Z20ira_reuse_stack_slotijj+152>: addil L%4d800,dp,r1 End of assembler dump. (gdb) p/x $r4 $3 = 0x0 (gdb) info addr allocno Symbol "allocno" is a variable in register r4.