This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: Build of snapshots failed on Solaris 2.6


This compile was done with:
(27) nathan@turing /proj/nathan/egcs/objdir-turing/gcc -> gcc -v
Reading specs from
/usr/local/gcc-2.8.1/lib/gcc-lib/sparc-sun-solaris2.5.1/2.8.1/specs
gcc version 2.8.1


>   > The error I'm getting is:
>   > 
>   > ./gengenrtl tmp-genrtl.h tmp-genrtl.c
>   > gmake[2]: *** [s-genrtl] Segmentation Fault
>   > gmake[2]: Leaving directory `/export/proj/nathan/egcs/objdir-turing/gcc'
>   > gmake[1]: *** [bootstrap] Error 2
>   > gmake[1]: Leaving directory `/export/proj/nathan/egcs/objdir-turing/gcc'
>   > gmake: *** [bootstrap] Error 2
> I recommend you start up gdb on gengenrtl and run it to see where it is 
> dying.
Ok, I'm not a gdb wizard, but here's what I've figured out.

First off, some context, here's the backtrace:

#0  0x9de3bf90 in ?? ()
#1  0x10aa0 in gendecl (f=0x23040, format=0x12379 "e")
    at ../../egcs-19990623/gcc/gengenrtl.c:179
#2  0x10e1c in genheader (f=0x23040) at
../../egcs-19990623/gcc/gengenrtl.c:266
#3  0x10fd8 in main (argc=143424, argv=0xeffffa04)
    at ../../egcs-19990623/gcc/gengenrtl.c:339

So we're dying in gendecl.  From there the we run:
179           fprintf (f, ", %s arg%d", type_from_format (*p), i++);
which segfaults.  I looked at all the variables and they seem fine, so I
tried running type_from_format(*p), which produced a seg fault:

 p type_from_format(*p)

Program received signal SIGSEGV, Segmentation fault.
0x9de3bf90 in ?? ()
The program being debugged stopped while in a function called from GDB.
When the function (type_from_format) is done executing, GDB will silently
stop (instead of continuing to evaluate the expression containing
the function call).  When I step into this I get the following, which
seems very strange to me:

(gdb) s
type_from_format (c=101) at ../../egcs-19990623/gcc/gengenrtl.c:62
62        switch (c)
(gdb) p c
$4 = 101
(gdb) s

Program received signal SIGSEGV, Segmentation fault.
0x9de3bf90 in ?? ()

Any ideas?  Is seems strange that a switch would seg fault.  If it would
help I could give you the core file.

	nathan

PS.  I'm not on the mailing list, if it would make things easier let me
know and I'll join until this has been resolved.

------------
Nathan Field  Root is not something to be shared with strangers.

"One World, One Web, One Program" - Microsoft Promotional Ad
"Ein Volk, Ein Reich, Ein Fuhrer" - Adolf Hitler


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]