public inbox for gcc@gcc.gnu.org
 help / color / mirror / Atom feed
* egcs-ss-19980425 won't bootstrap on alpha-unknown-linux-gnu
@ 1998-04-27 14:44 Alexandre Oliva
  1998-04-29 16:08 ` Jim Wilson
  0 siblings, 1 reply; 2+ messages in thread
From: Alexandre Oliva @ 1998-04-27 14:44 UTC (permalink / raw)
  To: egcs

Both haifa-enabled and haifa-disabled builds with BOOT_CFLAGS="-O4
-g" crash while building stage2:

./xgcc -B./  -DIN_GCC    -W -Wall -O4 -g -I./include  -I. -I/n/temp1/gcctest/bin/../src/egcs/gcc -I/n/temp1/gcctest/bin/../src/egcs/gcc/config \
-c /n/temp1/gcctest/bin/../src/egcs/gcc/objc/hash.c -o objc/hash.o
xgcc: Internal compiler error: program cc1 got fatal signal 11

haifa-disabled stack trace:

Program received signal SIGSEGV, Segmentation fault.
find_cross_jump (e1=0x1203e0138, e2=0x0, minimum=1, f1=0x11fffe908,
    f2=0x11fffe910) at /n/temp1/gcctest/bin/../src/egcs/gcc/jump.c:2556
2556          i2 = PREV_INSN (i2);
(gdb) where
#0  find_cross_jump (e1=0x1203e0138, e2=0x0, minimum=1, f1=0x11fffe908,
    f2=0x11fffe910) at /n/temp1/gcctest/bin/../src/egcs/gcc/jump.c:2556
#1  0x1200d0190 in jump_optimize (f=0x1203d8658, cross_jump=1,
    noop_moves=540934456, after_regscan=0)
    at /n/temp1/gcctest/bin/../src/egcs/gcc/jump.c:2141
#2  0x12003433c in rest_of_compilation (decl=0x12030eee8)
    at /n/temp1/gcctest/bin/../src/egcs/gcc/toplev.c:3533
#3  0x12001573c in finish_function (nested=0)
    at /n/temp1/gcctest/bin/../src/egcs/gcc/c-decl.c:7118
#4  0x1200020dc in yyparse () at c-parse.y:318
#5  0x12002f55c in compile_file (name=0x11ffff703 "hash.i")
    at /n/temp1/gcctest/bin/../src/egcs/gcc/toplev.c:2545
#6  0x120035bdc in main (argc=12, argv=0x11ffff440, envp=0x1)
    at /n/temp1/gcctest/bin/../src/egcs/gcc/toplev.c:4366
(gdb) p i2
$1 = (struct rtx_def *) 0x0

haifa-enabled stack trace:

Program received signal SIGSEGV, Segmentation fault.
find_cross_jump (e1=0x1203e7808, e2=0x0, minimum=1, f1=0x11fffe908, 
    f2=0x11fffe910) at /n/temp1/gcctest/bin/../src/egcs/gcc/jump.c:2556
2556          i2 = PREV_INSN (i2);
(gdb) where
#0  find_cross_jump (e1=0x1203e7808, e2=0x0, minimum=1, f1=0x11fffe908, 
    f2=0x11fffe910) at /n/temp1/gcctest/bin/../src/egcs/gcc/jump.c:2556
#1  0x1200d05e8 in jump_optimize (f=0x1203dfd28, cross_jump=1, 
    noop_moves=540964872, after_regscan=0)
    at /n/temp1/gcctest/bin/../src/egcs/gcc/jump.c:2141
#2  0x120034540 in rest_of_compilation (decl=0x1203165b8)
    at /n/temp1/gcctest/bin/../src/egcs/gcc/toplev.c:3533
#3  0x1200156fc in finish_function (nested=0)
    at /n/temp1/gcctest/bin/../src/egcs/gcc/c-decl.c:7118
#4  0x1200020d8 in yyparse () at c-parse.y:318
#5  0x12002f754 in compile_file (name=0x11ffff702 "hash.i")
    at /n/temp1/gcctest/bin/../src/egcs/gcc/toplev.c:2545
#6  0x120035ea4 in main (argc=12, argv=0x11ffff440, envp=0x1)
    at /n/temp1/gcctest/bin/../src/egcs/gcc/toplev.c:4366
(gdb) p i2
$1 = (struct rtx_def *) 0x0


This file can be successfully compiled with BOOT_CFLAGS="-O2 -g", but
objc/sarray.c will only compile with BOOT_CFLAGS="-O -g".

Hope this helps...

-- 
Alexandre Oliva
mailto:oliva@dcc.unicamp.br mailto:aoliva@acm.org
http://www.dcc.unicamp.br/~oliva
Universidade Estadual de Campinas, SP, Brasil


^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: egcs-ss-19980425 won't bootstrap on alpha-unknown-linux-gnu
  1998-04-27 14:44 egcs-ss-19980425 won't bootstrap on alpha-unknown-linux-gnu Alexandre Oliva
@ 1998-04-29 16:08 ` Jim Wilson
  0 siblings, 0 replies; 2+ messages in thread
From: Jim Wilson @ 1998-04-29 16:08 UTC (permalink / raw)
  To: Alexandre Oliva; +Cc: egcs

I get a similar error with a alpha-dec-osf3.2 BOOT_CFLAGS="-O4" build.
My build fails during the stage2 build of libgcc2.c.

This is an aliasing problem.  obstack_alloc_rtx in genrtl.c does this
to clear memory:
  rtx rt = (rtx) obstack_alloc (rtl_obstack, length);
  if (sizeof(struct rtx_def) - sizeof(rtunion) == sizeof(int))
    *(int *)rt = 0;

This code is really not correct, but it will happen to work without function
inlining because there is no chance of aliasing.  With function inlining, the
old aliasing code noticed overlapping addresses, and handled this OK.  The
new stricter code recognizes that this is invalid, and did not try to handle it
correctly.

Jfc has reverted the stricter type base checking for now, so this problem
should be gone.

We probably should fix the code anyways.  It would be nice to call memset
always, as we have builtin function support for memset, so we will still
get good code.  Unfortunately, gcc still requires calls to bzero, and we
have no builtin for that.

Jim

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~1998-04-29 16:08 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1998-04-27 14:44 egcs-ss-19980425 won't bootstrap on alpha-unknown-linux-gnu Alexandre Oliva
1998-04-29 16:08 ` Jim Wilson

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).