Summary: | Segfault on IA64, something to do with Unwind and section ordering | ||
---|---|---|---|
Product: | binutils | Reporter: | Ian Wienand <ianw> |
Component: | ld | Assignee: | unassigned |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | bug-binutils, hjl.tools |
Priority: | P2 | ||
Version: | 2.17 | ||
Target Milestone: | --- | ||
Host: | ia64-unknown-linux-gnu | Target: | |
Build: | Last reconfirmed: | ||
Attachments: |
kde object file
other object file unstripped object |
Description
Ian Wienand
2005-12-09 03:40:42 UTC
Created attachment 787 [details]
kde object file
an object file from qt/kde
Created attachment 788 [details]
other object file
other object file
moc_qassistantclient.o has [36] .gnu.linkonce.ia64unw._ZN7QShared5derefEv IA_64_UNWIND 0000000000000000 00000000000017c0 39 0000000000000018 0000000000000000 39 8 [0000000000000282]: ALLOC, LINK ORDER, GROUP [37] .rela.gnu.linkonce.ia64unw._ZN7QShared5derefEv RELA 0000000000000000 0000000000007060 88 0000000000000048 0000000000000018 36 8 [0000000000000000]: [38] .gnu.linkonce.t._Z7qstrcmpPKcS0_ PROGBITS 0000000000000000 00000000000017e0 0 00000000000001c0 0000000000000000 0 16 [0000000000000206]: ALLOC, EXEC, GROUP [39] .rela.gnu.linkonce.t._Z7qstrcmpPKcS0_ RELA 0000000000000000 00000000000070a8 88 0000000000000018 0000000000000018 38 8 [0000000000000000]: sh_link of .gnu.linkonce.ia64unw._ZN7QShared5derefEv is 39, which points to .rela.gnu.linkonce.t._Z7qstrcmpPKcS0_. It looks like moc_qassistantclient.o may be generated by "strip -g", which triggers bug 1991. The input is bogus. But linker should try to avoid crash. I will see what I can do. Ian, could you please provide the unstripped mainwindow.o and moc_qassistantclient.o? Created attachment 797 [details]
unstripped object
As you identified, the root cause does appear to be a slightly older strip. Using the CVS version doesn't create an object that makes ld segfault. $ ld-cvs -shared -o test.so moc_qassistantclient-unstripped.o ./mainwindow.o $ cp moc_qassistantclient-unstripped.o moc_qassistantclient.o $ strip-cvs --version GNU strip 2.16.91 20051208 Copyright 2005 Free Software Foundation, Inc. This program is free software; you may redistribute it under the terms of the GNU General Public License. This program has absolutely no warranty. $ strip-cvs -g ./moc_qassistantclient.o $ ld-cvs -shared -o test.so moc_qassistantclient.o ./mainwindow.o $ cp moc_qassistantclient-unstripped.o moc_qassistantclient.o $ strip --version GNU strip 2.16.91 20051206 Debian GNU/Linux Copyright 2005 Free Software Foundation, Inc. This program is free software; you may redistribute it under the terms of the GNU General Public License. This program has absolutely no warranty. $ strip -g ./moc_qassistantclient.o $ ld-cvs -shared -o test.so moc_qassistantclient.o ./mainwindow.o Segmentation fault A patch is posted at http://sourceware.org/ml/binutils/2005-12/msg00100.html Fixed. |