Bug 12801 - ICE in bfd/elf64-x86-64.c line 2764 in elf64_x86_64_relocate_section
Summary: ICE in bfd/elf64-x86-64.c line 2764 in elf64_x86_64_relocate_section
Status: RESOLVED DUPLICATE of bug 12366
Alias: None
Product: binutils
Classification: Unclassified
Component: ld (show other bugs)
Version: 2.21
: P2 normal
Target Milestone: ---
Assignee: unassigned
URL:
Keywords:
Depends on: 12366
Blocks:
  Show dependency treegraph
 
Reported: 2011-05-24 09:47 UTC by Richard Biener
Modified: 2011-05-25 15:36 UTC (History)
1 user (show)

See Also:
Host:
Target: x86_64-unknown-linux-gnu
Build:
Last reconfirmed:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Richard Biener 2011-05-24 09:47:15 UTC
Current glibc git head fails to link with ld from the 2.21 branch

> tar xjf ld-bug.tar.bz2
> cd ld-bug/
> ld -m elf_x86_64 -shared -o ./libc.so -e __libc_main -O1 -z defs --version-script=./libc.map -soname=libc.so.6 -z combreloc -z relro ./abi-note.o ./soinit.os --whole-archive ./libc_pic.a --no-whole-archive ./sofini.os ./interp.os ./ld.so -v -T ./shlib.lds
GNU ld (GNU Binutils; devel:gcc / openSUSE_11.1) 2.21.0.20110419-45
ld: BFD (GNU Binutils; devel:gcc / openSUSE_11.1) 2.21.0.20110419-45 internal
error, aborting at ../../bfd/elf64-x86-64.c line 2764 in
elf64_x86_64_relocate_section

ld: Please report this bug.

I suppose the testcase will be too large for bugzilla, you can fetch it
from http://gcc.opensuse.org/ld-bug.tar.bz2 once it is synced there.
Comment 1 Richard Biener 2011-05-24 09:51:15 UTC
ICEs the same way with the 2.21 release.  ld 2.16.91.0.5 doesn't grok the
linker script.

With

GNU ld (GNU Binutils; SUSE Linux Enterprise 11) 2.20.0.20100122-0.7.9

it works fine, so it seems to be a regression in 2.21.
Comment 2 H.J. Lu 2011-05-24 14:07:16 UTC
Please try binutils mainline.
Comment 3 Richard Biener 2011-05-25 08:35:48 UTC
I don't have mainline around.  I have 2.20 around which works and 2.21 and
the top of the 2.21 branch which both fail.
Comment 5 Richard Biener 2011-05-25 12:30:11 UTC
Why should I?  You can try yourself.  I want a fix for 2.21.x, not for 2.22+.
Comment 6 H.J. Lu 2011-05-25 15:36:11 UTC
Dup.

*** This bug has been marked as a duplicate of bug 12366 ***