labath accepted this revision. labath added a comment. This revision is now accepted and ready to land.
Nice catch. Regarding the implementation, I think it might be slightly cleaner (and slightly more consistent with the llvm dwarf parser) if the index handling has moved to the DWARFUnit class (as there's nothing to be gained now by doing it higher up). In `DWARFUnit::extract`, you could do something like: if (dwarf.GetDWARFContext().isDWO()) { cu_index = &dwarf.GetDWARFContext().GetAsLLVM().getCUIndex(); ... ================ Comment at: lldb/source/Plugins/SymbolFile/DWARF/DWARFUnit.cpp:808-809 + if (cu_index && (header.m_unit_type == llvm::dwarf::DW_UT_compile || + header.m_unit_type == llvm::dwarf::DW_UT_split_compile)) { + header.m_index_entry = cu_index->getFromOffset(header.m_offset); ---------------- I guess this could be `header.IsTypeUnit()` (and `!header.IsTypeUnit())`)... Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D96194/new/ https://reviews.llvm.org/D96194 _______________________________________________ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits