diff options
author | George Rimar <grimar@accesssoftek.com> | 2016-01-15 13:34:52 +0000 |
---|---|---|
committer | George Rimar <grimar@accesssoftek.com> | 2016-01-15 13:34:52 +0000 |
commit | f6bc65a3b2ef867955355a884ea125b6b3e4de40 (patch) | |
tree | 9000ea460e8e3941c8fe645f3db362df7a314130 /llvm/lib/Transforms/Utils/Local.cpp | |
parent | 9258e013a27c6d9715028c71195ac97c51feaa3e (diff) | |
download | llvm-f6bc65a3b2ef867955355a884ea125b6b3e4de40.zip llvm-f6bc65a3b2ef867955355a884ea125b6b3e4de40.tar.gz llvm-f6bc65a3b2ef867955355a884ea125b6b3e4de40.tar.bz2 |
Reapply r257753 with fix:
Added check for terminator CIE/FDE which has zero data size.
void EHOutputSection<ELFT>::addSectionAux(
...
// If CIE/FDE data length is zero then Length is 4, this
// shall be considered a terminator and processing shall end.
if (Length == 4)
break;
...
After this "Bug 25923 - lld/ELF2 linked application crashes if exceptions were used." is fixed for me. Self link of clang also works.
Initial commit message:
[ELF] - implemented --eh-frame-hdr command line option.
--eh-frame-hdr
Request creation of ".eh_frame_hdr" section and ELF "PT_GNU_EH_FRAME" segment header.
Both gold and the GNU linker support an option --eh-frame-hdr which tell them to construct a header for all the .eh_frame sections. This header is placed in a section named .eh_frame_hdr and also in a PT_GNU_EH_FRAME segment. At runtime the unwinder can find all the PT_GNU_EH_FRAME segments by calling dl_iterate_phdr.
This section contains a lookup table for quick binary search of FDEs.
Detailed info can be found here:
http://www.airs.com/blog/archives/462
Differential revision: http://reviews.llvm.org/D15712
llvm-svn: 257889
Diffstat (limited to 'llvm/lib/Transforms/Utils/Local.cpp')
0 files changed, 0 insertions, 0 deletions