This is the mail archive of the gas2@sourceware.cygnus.com mailing list for the gas2 project.


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

Re: ELF/x86 as error message




># gcc-elf -c loop.s
>loop.s: Assembler messages:
>loop.s:5: Error: Can not do 1 byte pc-relativerelocation
>
>Any reason for ELF/x86 as to do that?
>
>Thanks.
>
>-- 
>H.J. Lu
>NYNEX Science and Technology, Inc.			hjl@nynexst.com
>------
>	.text
>.byteloop:
>         movb %al, (%edi)
>         leal  1(%ebx,%edi),%edi
>         loop .byteloop
 
	With ELF, there are no 1 byte relocations, so if this is going to be resolved,
it has to be done in such a way that no external relocations are generated.  Since
this is PC-relative, I think this can be done, so I suspect that we simply need to fix
gas so that when these relocations are generated internally that the backend performs
the relocations itself.  In principle it should not be that bad.

	How well does the latest snapshot of GAS work?  Ken claims to have fixed things.

-Eric