[all-commits] [llvm/llvm-project] 26ca2f: [DebugInfo] Parse StrOffsets section if needed
Felipe de Azevedo Piovezan via All-commits
all-commits at lists.llvm.org
Mon Sep 11 06:59:37 PDT 2023
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 26ca2f47c1373f20215994e844a30d1f6173268d
https://github.com/llvm/llvm-project/commit/26ca2f47c1373f20215994e844a30d1f6173268d
Author: Felipe de Azevedo Piovezan <fpiovezan at apple.com>
Date: 2023-09-11 (Mon, 11 Sep 2023)
Changed paths:
M llvm/include/llvm/DebugInfo/DWARF/DWARFUnit.h
M llvm/test/DebugInfo/X86/dwarfdump-str-offsets.s
Log Message:
-----------
[DebugInfo] Parse StrOffsets section if needed
Querying the debug_str_offsets section requires parsing the top level DIE of the
CU (as well as the section itself); the current getter, however, assumes this is
done elsewhere. This patch changes the getter behavior to match what is done in
other getter methods (e.g. `getCompilationDir` or `getVariableForAddress`), in
other words, `extractDIEsIfNeeded` is now called prior to returning the
debug_str_offsets contributions for the Unit.
One way in which this bug manifested is when `dwarfdump --debug-str-offsets` is
invoked: because the DIEs are never parsed, we incorrectly print an empty
section (with no warnings or errors).
Differential Revision: https://reviews.llvm.org/D159484
More information about the All-commits
mailing list