mips: disable combreloc for NEWABI

Alexandre Oliva aoliva@redhat.com
Sat Oct 19 14:52:00 GMT 2002


On Oct 19, 2002, "H. J. Lu" <hjl@lucon.org> wrote:

> On Sat, Oct 19, 2002 at 06:22:15PM -0300, Alexandre Oliva wrote:
>> As explained in the comments introduced in the patch below, combreloc
>> breaks with the n64 ABI, because n64 packs three consecutive
>> relocations in one.  I've only noticed problems on n64, but n32 also
>> composes relocations, so I thought I'd leave combreloc disabled for it
>> too.  I might also have gone ahead and disabled combreloc for all mips
>> emulations, since the only dynamic relocation is RELATIVE anyway, so
>> there's no benefit in combining relocations.  Thoughts?  Ok to
>> install?

> Follow

> http://sources.redhat.com/ml/binutils/2002-04/msg00374.html

Thanks for the pointer.  I agree with Jakub and Alan Modra that we
still do some sorting, but the only situation in which it might be
useful is when it groups relative relocations that apply to the same
page, or the same cache line.  I believe we already get this behavior
without resorting to sorting :-), since we only have one kind of
dynamic relocation, namely, RELATIVE.

Anyway, I'd trade a slight speed up at dynamic load time for the
absence of crashes in the static linker any time :-) The current
reloc-sorting code breaks an assumption (perhaps unduly) made by the
elf64-mips swap_reloc functions.  I'd rather have it work first, and
perhaps optimize it later, than having to choose between not having
something that works or risking to break all other architectures that
use (and have come to depend on) combreloc.

-- 
Alexandre Oliva   Enjoy Guarana', see http://www.ic.unicamp.br/~oliva/
Red Hat GCC Developer                 aoliva@{redhat.com, gcc.gnu.org}
CS PhD student at IC-Unicamp        oliva@{lsd.ic.unicamp.br, gnu.org}
Free Software Evangelist                Professional serial bug killer



More information about the Binutils mailing list