In our SW build we have a pre-compiled library that is linked with gnuld: ld -r -EL -o precompiled.a module1.o module2.o ...
When this library is linked together with other objects with gold I get an internal error: $ build/gold/ld-new -r -o test.a precompiled_gnuld.a build/gold/ld-new: internal error in output_symtab_index, at ../../binutils-2.19/gold/object.h:968 If I create precompiled.a with gold from the same object files everything works fine. The resulting libraries are different: -rw-r--r-- 1 user group 2332299 2008-12-10 12:01 precompiled_gnuld.a -rw-r--r-- 1 user group 2317681 2008-12-10 12:36 precompiled_gold.a "--debug all" shows: /disks/sausers9/stefanb/workarea/gold_linker/build/gold/ld-new: 0 running task Dir_cache_task /lib /disks/sausers9/stefanb/workarea/gold_linker/build/gold/ld-new: 0 completed task Dir_cache_task /lib /disks/sausers9/stefanb/workarea/gold_linker/build/gold/ld-new: 0 running task Dir_cache_task /usr/lib /disks/sausers9/stefanb/workarea/gold_linker/build/gold/ld-new: 0 completed task Dir_cache_task /usr/lib /disks/sausers9/stefanb/workarea/gold_linker/build/gold/ld-new: 0 running task Read_symbols precompiled_gnuld.a /disks/sausers9/stefanb/workarea/gold_linker/build/gold/ld-new: Attempt to open precompiled_gnuld.a succeeded /disks/sausers9/stefanb/workarea/gold_linker/build/gold/ld-new: 0 completed task Read_symbols precompiled_gnuld.a /disks/sausers9/stefanb/workarea/gold_linker/build/gold/ld-new: 0 running task Add_symbols precompiled_gnuld.a /disks/sausers9/stefanb/workarea/gold_linker/build/gold/ld-new: 0 completed task Add_symbols precompiled_gnuld.a /disks/sausers9/stefanb/workarea/gold_linker/build/gold/ld-new: 0 running task Task_function Middle_runner /disks/sausers9/stefanb/workarea/gold_linker/build/gold/ld-new: Dumping linker script /disks/sausers9/stefanb/workarea/gold_linker/build/gold/ld-new: 0 completed task Task_function Middle_runner /disks/sausers9/stefanb/workarea/gold_linker/build/gold/ld-new: 0 running task Read_relocs precompiled_gnuld.a /disks/sausers9/stefanb/workarea/gold_linker/build/gold/ld-new: 0 completed task Read_relocs precompiled_gnuld.a /disks/sausers9/stefanb/workarea/gold_linker/build/gold/ld-new: 0 running task Scan_relocs precompiled_gnuld.a /disks/sausers9/stefanb/workarea/gold_linker/build/gold/ld-new: 0 completed task Scan_relocs precompiled_gnuld.a /disks/sausers9/stefanb/workarea/gold_linker/build/gold/ld-new: 0 running task Task_function Layout_task_runner /disks/sausers9/stefanb/workarea/gold_linker/build/gold/ld-new: 0 completed task Task_function Layout_task_runner /disks/sausers9/stefanb/workarea/gold_linker/build/gold/ld-new: 0 running task Write_symbols_task /disks/sausers9/stefanb/workarea/gold_linker/build/gold/ld-new: 0 completed task Write_symbols_task /disks/sausers9/stefanb/workarea/gold_linker/build/gold/ld-new: 0 running task Write_sections_task /disks/sausers9/stefanb/workarea/gold_linker/build/gold/ld-new: 0 completed task Write_sections_task /disks/sausers9/stefanb/workarea/gold_linker/build/gold/ld-new: 0 running task Write_data_task /disks/sausers9/stefanb/workarea/gold_linker/build/gold/ld-new: 0 completed task Write_data_task /disks/sausers9/stefanb/workarea/gold_linker/build/gold/ld-new: 0 running task Relocate_task precompiled_gnuld.a /disks/sausers9/stefanb/workarea/gold_linker/build/gold/ld-new: internal error in output_symtab_index, at ../../binutils-2.19/gold/object.h:968 GDB shows the following backtrace when the assert happens: #0 gold::do_gold_unreachable ( filename=0x81a79a4 "../../binutils-2.19/gold/object.h", lineno=968, function=0x81a7fe0 "output_symtab_index") at ../../binutils-2.19/gold/gold.cc:84 #1 0x0806017f in gold::relocate_for_relocatable<32, false, 9> ( relinfo=0xbfac42b0, prelocs=0xb7fffe00 "\022", reloc_count=4329, output_section=0xa3c00a0, offset_in_output_section=0, rr=0xa4247f0, view=0xb7ed5ff8 "\030", view_address=0, reloc_view=0xb7f33a64 "\022", reloc_view_size=34632) at ../../binutils-2.19/gold/object.h:968 #2 0x08123348 in gold::Sized_relobj<32, false>::relocate_sections ( this=0xa1b4ab0, [EMAIL PROTECTED], symtab=0xbfac5ca0, layout=0xbfac5b14, pshdrs=0xb8080f80 "", pviews=0xbfac4330) at ../../binutils-2.19/gold/reloc.cc:803 #3 0x08125e67 in gold::Sized_relobj<32, false>::do_relocate (this=0xa1b4ab0, [EMAIL PROTECTED], symtab=0xbfac5ca0, layout=0xbfac5b14, of=0xa52e6f0) at ../../binutils-2.19/gold/reloc.cc:486 #4 0x0811d421 in gold::Relocate_task::run (this=0xa52e7d8) at ../../binutils-2.19/gold/object.h:628 #5 0x0815b8e7 in gold::Workqueue::find_and_run_task (this=0xbfac5e80, thread_number=0) at ../../binutils-2.19/gold/workqueue.cc:314 #6 0x0815bb8c in gold::Workqueue::process (this=0xbfac5e80, thread_number=0) at ../../binutils-2.19/gold/workqueue.cc:480 #7 0x0804ac04 in main (argc=-1079227524, argv=0x1) at ../../binutils-2.19/gold/main.cc:219 As I'm not allowed to distribute the precompiled library I hope you can tell me what additional information I would need to collect for your error analysis. -- Summary: Internal error on object generated by gnuld Product: binutils Version: 2.19 Status: NEW Severity: normal Priority: P2 Component: gold AssignedTo: ian at airs dot com ReportedBy: stefan dot becker at nokia dot com CC: bug-binutils at gnu dot org GCC host triplet: i386-redhat-linux-gnu http://sourceware.org/bugzilla/show_bug.cgi?id=7091 ------- You are receiving this mail because: ------- You are on the CC list for the bug, or are watching someone who is. _______________________________________________ bug-binutils mailing list bug-binutils@gnu.org http://lists.gnu.org/mailman/listinfo/bug-binutils