This is the mail archive of the
binutils@sourceware.cygnus.com
mailing list for the binutils project.
Re: Psossible problem with gas on MIPS
- To: "Koundinya.K" <kk at ddeorg dot soft dot net>
- Subject: Re: Psossible problem with gas on MIPS
- From: "Maciej W. Rozycki" <macro at ds2 dot pg dot gda dot pl>
- Date: Thu, 8 Jun 2000 17:33:20 +0200 (MET DST)
- cc: binutils at sourceware dot cygnus dot com
- Organization: Technical University of Gdansk
- Reply-To: "Maciej W. Rozycki" <macro at ds2 dot pg dot gda dot pl>
On Thu, 8 Jun 2000, Koundinya.K wrote:
> li.s: Assembler messages:
> li.s:3: Error: Can not represent BFD_RELOC_16_PCREL_S2 relocation in this
> object file format
>
> Could this be a possible bug in gas ?. I am looking at the source too. Could
> someone having access to MIPS boxes try this test case and verify ?
I recall myself discussing this issue here back in October. The
conclusion was that due to a limited range and thus a questionable
usefulness relocations for branches are not defined by the MIPS ELF ABI.
I prepared a patch to map BFD_RELOC_16_PCREL_S2 to R_MIPS_PC16 then but it
got rejected as not being ABI-compliant.
A R_MIPS_PC16 relocation that the vendor-supplied as generates in not
appropriate for branches. That's beacuse R_MIPS_PC16 is defined as a
simple difference between two addresses in the ABI while for branches you
need a shifted left by two difference.
--
+ Maciej W. Rozycki, Technical University of Gdansk, Poland +
+--------------------------------------------------------------+
+ e-mail: macro@ds2.pg.gda.pl, PGP key available +