llvm-project/lldb/lit/SymbolFile
Pavel Labath 78cfe1e6fe DWARF: Fix address range support in mixed 4+5 scenario
Summary:
debug_ranges got renamed to debug_rnglists in DWARF 5. Prior to this
patch lldb was just picking the first section it could find in the file,
and using that for all address ranges lookups. This is not correct in
case the file contains a mixture of compile units with various standard
versions (not a completely unlikely scenario).

In this patch I make lldb support reading from both sections
simulaneously, and decide the correct section to use based on the
version number of the compile unit. SymbolFileDWARF::DebugRanges is
split into GetDebugRanges and GetDebugRngLists (the first one is renamed
mainly so we can catch all incorrect usages).

I tried to structure the code similarly to how llvm handles this logic
(hence DWARFUnit::FindRnglistFromOffset/Index), but the implementations
are still relatively far from each other.

Reviewers: JDevlieghere, aprantl, clayborg

Subscribers: lldb-commits

Differential Revision: https://reviews.llvm.org/D62302

llvm-svn: 361938
2019-05-29 09:22:36 +00:00
..
Breakpad [FuncUnwinders] Use "symbol file" unwind plans for unwinding 2019-05-24 09:54:39 +00:00
DWARF DWARF: Fix address range support in mixed 4+5 scenario 2019-05-29 09:22:36 +00:00
Inputs [lldb] [lit/SymbolFile] Avoid -nostdlib in target-symbols-add-unwind.test 2019-04-13 09:49:39 +00:00
NativePDB [NativePDB] Fix tests after r360569 2019-05-13 15:06:13 +00:00
PDB [NativePDB] Add anonymous namespaces support 2019-04-22 07:14:40 +00:00
target-symbols-add-unwind.test [lldb] [lit/SymbolFile] Avoid -nostdlib in target-symbols-add-unwind.test 2019-04-13 09:49:39 +00:00