This is the mail archive of the gcc-patches@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: 3.0 PATCH RFC: Major Solaris 2 configuration cleanup


On May 29, 2001, Paul Eggert <eggert@twinsun.com> wrote:

> It's just my intuition, in looking at the assembly language output.
> Unlike GCC 2.8.0, GCC 2.95.3 (gcc -gdwarf) generates code like this:

> 		.pushsection	".text"
> 	.L_text_b:
> 		.popsection

> and where GCC 2.8.0 later has expressions involving the value ".text",

Ok, I managed to get the assembler to crash by following the code
above with:

.byte 0
.uaword .text

>> I do have access to a Solaris 2.6 machine

> Is it a vanilla 2.6 machine, or does it have the assembler and linker
> patches installed?

None of the patches you mentioned are installed.

> Ideally, you would try it without those patches on a vanilla 2.6 host,
> as well as on a host with those patches installed.

I'm afraid I don't have administrative access to this machine to
install patches on it.

> An explicit -gdwarf-2 overrides LINKER_DOES_NOT_WORK_WITH_DWARF2, so
> to reproduce the problem, here's all that you should need to do:

>         echo 'main() { return 0; }' >t.c
>         gcc -gdwarf-2 t.c

> Make sure your GCC uses Sun 'as' and Sun 'ld'.

Done.  The assembler crash is no longer there, but the linker still
complains:

ld: Software Generation Utilities - Solaris/ELF (3.0)
ld: fatal: relocation error: R_SPARC_32: file t.o:  symbol <unknown>:  offset 0xef30153a is non-aligned

-- 
Alexandre Oliva   Enjoy Guarana', see http://www.ic.unicamp.br/~oliva/
Red Hat GCC Developer                  aoliva@{cygnus.com, redhat.com}
CS PhD student at IC-Unicamp        oliva@{lsd.ic.unicamp.br, gnu.org}
Free Software Evangelist    *Please* write to mailing lists, not to me


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