[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Bug ld/16563] Corrupt .eh-frame section created when linking LTO and no
From: |
amodra at gmail dot com |
Subject: |
[Bug ld/16563] Corrupt .eh-frame section created when linking LTO and non-LTO objects |
Date: |
Wed, 13 Aug 2014 14:46:27 +0000 |
https://sourceware.org/bugzilla/show_bug.cgi?id=16563
--- Comment #4 from Alan Modra <amodra at gmail dot com> ---
There are a couple of things going on here, but the "Invalid CIE pointer" is a
readelf bug I'd say. There's nothing prohibiting a FDE to be located before
its CIE. The .eh_frame cie_id is a signed relative offset (gcc's unwinder
treats it that way), and .debug_frame cie_id is section relative. So readelf
ought to be able to handle this ordering.
Of course it's unexpected to find CIEs and FDEs like this. The reason appears
to be that the elf-eh-frame.c code finds a duplicate CIE in a.o and b.o, and
therefore causes the b.o copy to be removed and some b.o FDE's then use an a.o
CIE. That's all quite nornal, use the CIE the elf-eh-frame.c sees as
"earlier".
The problem is that a.o's lto recompiled object actually gets linked into the
output .eh_frame *after* b.o's .eh_frame.
--
You are receiving this mail because:
You are on the CC list for the bug.
- [Bug ld/16563] Corrupt .eh-frame section created when linking LTO and non-LTO objects, nickc at redhat dot com, 2014/08/12
- [Bug ld/16563] Corrupt .eh-frame section created when linking LTO and non-LTO objects, nickc at redhat dot com, 2014/08/12
- [Bug ld/16563] Corrupt .eh-frame section created when linking LTO and non-LTO objects,
amodra at gmail dot com <=
- [Bug ld/16563] Corrupt .eh-frame section created when linking LTO and non-LTO objects, amodra at gmail dot com, 2014/08/13
- [Bug ld/16563] Corrupt .eh-frame section created when linking LTO and non-LTO objects, amodra at gmail dot com, 2014/08/13
- [Bug ld/16563] Corrupt .eh-frame section created when linking LTO and non-LTO objects, cvs-commit at gcc dot gnu.org, 2014/08/14
- [Bug ld/16563] Corrupt .eh-frame section created when linking LTO and non-LTO objects, amodra at gmail dot com, 2014/08/14
- [Bug ld/16563] Corrupt .eh-frame section created when linking LTO and non-LTO objects, nickc at redhat dot com, 2014/08/15