]> granicus.if.org Git - llvm/commit
[dwarfdump] Make .eh_frame an alias for .debug_frame
authorJonas Devlieghere <jonas@devlieghere.com>
Mon, 18 Sep 2017 14:15:57 +0000 (14:15 +0000)
committerJonas Devlieghere <jonas@devlieghere.com>
Mon, 18 Sep 2017 14:15:57 +0000 (14:15 +0000)
commit6ad4356f4dd70cae00ec397ad52f08f87cb6182b
tree237a0390898fcf8cf9a4204be80aa347310afe3f
parent70c6728fba514c1e41b48547911b554d0afe71e9
[dwarfdump] Make .eh_frame an alias for .debug_frame

This patch makes the `.eh_frame` extension an alias for `.debug_frame`.
Up till now it was only possible to dump the section using objdump, but
not with dwarfdump. Since the two are essentially interchangeable, we
dump whichever of the two is present.

As a workaround, this patch also adds parsing for 3 currently
unimplemented CFA instructions: `DW_CFA_def_cfa_expression`,
`DW_CFA_expression`, and `DW_CFA_val_expression`. Because I lack the
required knowledge, I just parse the fields without actually creating
the instructions.

Finally, this also fixes the typo in the `.debug_frame` section name
which incorrectly contained a trailing `s`.

Differential revision: https://reviews.llvm.org/D37852

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@313530 91177308-0d34-0410-b5e6-96231b3b80d8
13 files changed:
include/llvm/BinaryFormat/Dwarf.def
include/llvm/DebugInfo/DIContext.h
include/llvm/DebugInfo/DWARF/DWARFContext.h
lib/DebugInfo/DWARF/DWARFContext.cpp
lib/DebugInfo/DWARF/DWARFDebugFrame.cpp
test/DebugInfo/dwarfdump-debug-frame-simple.test
test/MC/X86/i386-darwin-frame-register.ll
test/tools/dsymutil/X86/frame-1.test
test/tools/dsymutil/X86/frame-2.test
tools/llvm-dwarfdump/llvm-dwarfdump.cpp
tools/llvm-objdump/MachODump.cpp
tools/llvm-objdump/llvm-objdump.cpp
unittests/DebugInfo/DWARF/DWARFDebugInfoTest.cpp