public inbox for binutils@sourceware.org
 help / color / mirror / Atom feed
* [Query] : Usage of single LO relocation
@ 2006-04-21 14:55 Amarnath
  2006-04-21 17:42 ` Thiemo Seufer
  0 siblings, 1 reply; 2+ messages in thread
From: Amarnath @ 2006-04-21 14:55 UTC (permalink / raw)
  To: 'BinutilsAtRedhat'

As per my previous query results, I have observed that we should have HI
relocation and LO relocation immediately following each other.

With that as reference, a new query has been raised for me. Please check
it. 

Query 1
-------
If we have multiple LO relocations emitted for a single HI relocation as
following patterns, will the second LO relocation be utilized for any
purpose by the GCC linker?

Pattern
-------
R_MIPS_HI16
R_MIPS_LO16
R_MIPS_LO16   <-- Will linker utilize it for some relocations?


Query 2
-------
As I have examined, I have not yet found any usage of LO relocation as a
separate one. Can we have usage of LO relocation without HI relocation
in any case?

Please clarify it.


Regards,
Amarnath M

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

* Re: [Query] : Usage of single LO relocation
  2006-04-21 14:55 [Query] : Usage of single LO relocation Amarnath
@ 2006-04-21 17:42 ` Thiemo Seufer
  0 siblings, 0 replies; 2+ messages in thread
From: Thiemo Seufer @ 2006-04-21 17:42 UTC (permalink / raw)
  To: Amarnath; +Cc: 'BinutilsAtRedhat'

Amarnath wrote:
> As per my previous query results, I have observed that we should have HI
> relocation and LO relocation immediately following each other.
> 
> With that as reference, a new query has been raised for me. Please check
> it. 
> 
> Query 1
> -------
> If we have multiple LO relocations emitted for a single HI relocation as
> following patterns, will the second LO relocation be utilized for any
> purpose by the GCC linker?
> 
> Pattern
> -------
> R_MIPS_HI16
> R_MIPS_LO16
> R_MIPS_LO16   <-- Will linker utilize it for some relocations?

Yes, assuming all three refer to the same symbol, the last LO16 will
also use the data from the preceeding HI16. This is the GNU
extension to the original ABI requirement, IIRC there's some random
comment in the gas source which explains it a bit.

> Query 2
> -------
> As I have examined, I have not yet found any usage of LO relocation as a
> separate one. Can we have usage of LO relocation without HI relocation
> in any case?

No, since it can't find the the high part of the relocation then.
That's a limitation caused by the REL relocation format used for o32.


Thiemo

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

end of thread, other threads:[~2006-04-21 10:30 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-04-21 14:55 [Query] : Usage of single LO relocation Amarnath
2006-04-21 17:42 ` Thiemo Seufer

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).