[Lldb-commits] [PATCH] D40473: DWZ 10/12: Adjust existing code for the DWZ support.

Greg Clayton via Phabricator via lldb-commits lldb-commits at lists.llvm.org
Mon Nov 27 11:05:46 PST 2017


clayborg requested changes to this revision.
clayborg added inline comments.
This revision now requires changes to proceed.


================
Comment at: source/Plugins/SymbolFile/DWARF/DWARFDebugInfo.cpp:199-202
+  if (die_ref.cu_offset == DW_INVALID_OFFSET
+      // FIXME: Workaround default cu_offset = 0 in DIERef ctor.
+      // Why does GetCompileUnit exist at all?
+      || (die_ref.cu_offset == 0 /* && m_dwarf2Data->GetDWZSymbolFile() */ ))
----------------
Just fix the DIERef constructor to not use 0 for the cu_offset?


================
Comment at: source/Plugins/SymbolFile/DWARF/DWARFDebugInfoEntry.cpp:388-390
+  // DIERef(DWARFFormValue)->DWARFFormValue::Reference() may need
+  // FileOffsetToUniqOffset.
+  dwarf2Data->PreloadSymbols();
----------------
This seems like the wrong place to do this call. We are asking all DWARF to index itself from DWARFDebugInfoEntry::GetDIENamesAndRanges()? Doesn't seem like the right place.


https://reviews.llvm.org/D40473





More information about the lldb-commits mailing list