[all-commits] [llvm/llvm-project] 79f22b: Fix .debug_aranges parsing.

Greg Clayton via All-commits all-commits at lists.llvm.org
Tue Sep 15 11:51:22 PDT 2020


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: 79f22b1f99fd72db9a45c387258d289791f2b9c0
      https://github.com/llvm/llvm-project/commit/79f22b1f99fd72db9a45c387258d289791f2b9c0
  Author: Greg Clayton <gclayton at fb.com>
  Date:   2020-09-15 (Tue, 15 Sep 2020)

  Changed paths:
    M lldb/source/Plugins/SymbolFile/DWARF/DWARFDebugAranges.cpp
    M lldb/unittests/SymbolFile/DWARF/SymbolFileDWARFTests.cpp

  Log Message:
  -----------
  Fix .debug_aranges parsing.

Code was added that used llvm error checking to parse .debug_aranges, but the error check after parsing the DWARFDebugArangesSet was reversed and was causing no error to be returned with no valid address ranges being actually used. This meant we always would fall back onto creating out own address ranges by parsing the compile unit's ranges. This was causing problems for cases where the DW_TAG_compile_unit had a single address range by using a DW_AT_low_pc and DW_AT_high_pc attribute pair (not using a DW_AT_ranges attribute), but the .debug_aranges had correct split ranges. In this case we would end up using the single range for the compile unit that encompassed all of the ranges from the .debug_aranges section and would cause address resolving issues in LLDB where address lookups would fail for certain addresses.

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




More information about the All-commits mailing list