This is the mail archive of the
binutils@sources.redhat.com
mailing list for the binutils project.
Re: reducing reloc syms to section syms
On Tue, May 07, 2002 at 02:00:54AM -0700, Ian Lance Taylor wrote:
> Alan Modra <amodra@bigpond.net.au> writes:
>
> > Is there any benefit in reducing just some relocs using a given symbol
> > to the section symbol, and not others?
>
> It's slightly faster to compute a relocation against a section symbol,
> since it doesn't require a symbol lookup and doesn't require the
> various cases which can arise with a symbol. This is particularly
> true if the relocation becomes a dynamic relocation.
OK, let's ignore the linker for the moment. I'm not too worried about
link time, which tends to be fairly small compared to compile time.
What I'm more concerned about is differences in dynamic linker time,
file size, and suchlike that might affect a user. Seems to me that
dynamic linker time won't be affected much given Jakub's reloc
sorting code, and we're not adding anything to the symbol table so
file size shouldn't suffer.
--
Alan Modra
IBM OzLabs - Linux Technology Centre