[RFC] Providing init_fini_syms earlier?
H. J. Lu
hjl@lucon.org
Tue Jul 5 16:24:00 GMT 2005
On Tue, Jul 05, 2005 at 10:13:43AM -0400, Carlos O'Donell wrote:
>
> binutils,
>
> If I provide the __init_array_start, __init_array_end,
> __fini_array_start and __fini_array_end symbols earlier, in particular
> before sizing of the dynamic sections, the code has a chance at removing
> a possibly hidden local symbol.
>
> A quick test with the following patch is successfull at removing the
> extra R_PARISC_NONE relocs which are allocated to these symbosls but
> never used. They are allocated because the provides comes after the
> sizing and the symbol is assumed to be undefined dynamic. Once the
> sizing is done the symbol is added and it's too late to remove those
> entries.
>
> I don't believe this patch is correct, a gut feeling says these
> symbols should be provided at the last possible instance.
>
> Comments and insight appreciated?
>
> This patch *does* fix the linker, and R_PARISC_NONE extra relocs are no
> longer emitted. I don't suggest applying this patch, it's just to start
> a discussion.
>
Can you try
http://sourceware.org/ml/binutils/2005-05/msg00767.html
You may have to adjust it a little bit by hand.
H.J.
More information about the Binutils
mailing list