Clean up platform-specific code in gas/write.c
Alexandre Oliva
aoliva@redhat.com
Sat Aug 19 10:07:00 GMT 2000
On Aug 17, 2000, Jeffrey A Law <law@cygnus.com> wrote:
> The long term plan is to grovel over those targets' definition of
> md_apply_fix and fix them up -- which would eventually allow
> TC_DONT_FIX_NON_ADJUSTABLE to go away. But for now we'll keep it to
> avoid accidentally breaking a lot of ports.
But meanwhile, it seems that we may need one more instance of it.
I've been playing with deferring PCREL relocations of non_adjustable
symbols to the linker on SH, and found not only a couple of
limitations in the SH linker (patch to follow), but also the need to
not apply the negative relocation of PC. I wonder if existing ports
compensate for it too, and we need yet another target-specific macro,
or we can just reuse TC_DONT_FIX_NON_ADJUSTABLE.
Another alternative would be to have TC_DONT_FIX_NON_ADJUSTABLE be
called as a macro to tell whether to apply the relocation. Then, it
could decide whether to apply it based on the relocation type.
Presumably, PC-relative relocations should not be deferred to the
linker, since they may be limited in range.
Here's the patch I'm currently playing with. I'm not sure I like it,
but maybe someone else does... :-)
More information about the Binutils
mailing list