1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-24 19:52:54 +01:00
llvm-mirror/lib/ObjectYAML
Pavel Labath e992eb498a Recommit "[DWARF] Add an api to get "interpreted" location lists"
This recommits 089c0f581492cd6e2a3d2927be3fbf60ea2d7e62, which was
reverted due to failing tests on big endian machines. It includes a fix
which I believe (I don't have BE machine) should fix this issue. The fix
consists of correcting the invocation DWARFYAML::EmitDebugSections,
which was missing one (default) function arguments, and so didn't
actually force the little-endian mode.

The original commit message follows.

Summary:
This patch adds DWARFDie::getLocations, which returns the location
expressions for a given attribute (typically DW_AT_location). It handles
both "inline" locations and references to the external location list
sections (currently only of the DW_FORM_sec_offset type). It is
implemented on top of DWARFUnit::findLoclistFromOffset, which is also
added in this patch. I tried to make their signatures similar to the
equivalent range list functionality.

The actual location list interpretation logic is in
DWARFLocationTable::visitAbsoluteLocationList. This part is not
equivalent to the range list code, but this deviation is motivated by a
desire to reuse the same location list parsing code within lldb.

The functionality is tested via a c++ unit test of the DWARFDie API.

Reviewers: dblaikie, JDevlieghere, SouraVX

Subscribers: mgorny, hiraditya, cmtice, probinson, llvm-commits, aprantl

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D70394
2019-11-20 16:24:11 +01:00
..
CMakeLists.txt
CodeViewYAMLDebugSections.cpp
CodeViewYAMLSymbols.cpp
CodeViewYAMLTypeHashing.cpp
CodeViewYAMLTypes.cpp
COFFEmitter.cpp [yaml2obj][COFF] Add support for extended relocation tables 2019-11-14 12:39:28 -08:00
COFFYAML.cpp
DWARFEmitter.cpp Recommit "[DWARF] Add an api to get "interpreted" location lists" 2019-11-20 16:24:11 +01:00
DWARFVisitor.cpp
DWARFVisitor.h
DWARFYAML.cpp
ELFEmitter.cpp [yaml2obj/obj2yaml] - Add support for SHT_LLVM_LINKER_OPTIONS sections. 2019-11-12 09:55:20 +03:00
ELFYAML.cpp [yaml2obj/obj2yaml] - Add support for SHT_LLVM_LINKER_OPTIONS sections. 2019-11-12 09:55:20 +03:00
LLVMBuild.txt
MachOEmitter.cpp Fix a typo in my previous commit 2019-11-06 11:42:30 -08:00
MachOYAML.cpp
MinidumpEmitter.cpp
MinidumpYAML.cpp
ObjectYAML.cpp
WasmEmitter.cpp
WasmYAML.cpp
XCOFFYAML.cpp
yaml2obj.cpp
YAML.cpp [FixBB] - Fix one more std::min -> std::min<uint64_t> to make BB happy. 2019-11-11 12:11:54 +03:00