mips4/32-el BFD breakage
Pjotr Kourzanov
peter.kourzanov@xs4all.nl
Mon Mar 7 16:22:00 GMT 2005
Dear binutils developers,
Having dug into a particularly nasty problem of crashing applications
that use huge shared libraries (>40000 symbols) under a MIPS4,
little-endian target (I think the problem is MIPS generic, so it affects
MIPS3 as well) with Linux 2.4 kernel and GLIBC 2.3.2, I came up with the
attached two patches (one for 2.15, another one for the CVS MAIN).
It seems that a change to BFD broke GLIBC's dynamic loader, which
just gets a SIGSEGV whenever an application tries to link to huge shared
libraries in _dl_map_object_deps.
I have traced the problem to this change:
2003-11-17 Daniel Jacobowitz <drow@mvista.com>
* elf.c (_bfd_elf_link_hash_copy_indirect): Copy
ELF_LINK_HASH_NEEDS_PLT.
It apparently introduces ELF_LINK_HASH_NEEDS_PLT handling in
_bfd_elf_link_hash_copy_indirect which is bogus on (at least) my MIPS
with huge shared objects.
As a workaround, I've reverted this particular change by copying the
_bfd_elf_link_hash_copy_indirect implementation from elf.c to
elfxx-mips.c (suffixing it with "_mips") and disabling copying of the
ELF_LINK_HASH_NEEDS_PLT flag.
As I am not a MIPS binutils expert, could one of you shed light on why
this change was required?
Thanks in advance,
Pjotr Kourzanov
-------------- next part --------------
A non-text attachment was scrubbed...
Name: fix-shlib-bug-2.15.patch
Type: text/x-patch
Size: 2300 bytes
Desc: not available
URL: <https://sourceware.org/pipermail/binutils/attachments/20050307/fc23d62a/attachment.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: fix-shlib-bug-2.16.patch
Type: text/x-patch
Size: 2271 bytes
Desc: not available
URL: <https://sourceware.org/pipermail/binutils/attachments/20050307/fc23d62a/attachment-0001.bin>
More information about the Binutils
mailing list