Skip to content

Commit 0777849

Browse files
authored
[BOLT][DWARF] Fix debug info update issue with dwarf4 dwp (#155619)
Fix the crash issue when updating debuginfo via DWARF4 DWP and improve efficiency.
1 parent 52b59b5 commit 0777849

File tree

3 files changed

+813
-3
lines changed

3 files changed

+813
-3
lines changed

bolt/lib/Rewrite/DWARFRewriter.cpp

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -504,9 +504,7 @@ static void emitDWOBuilder(const std::string &DWOName,
504504
}
505505
emitUnit(DWODIEBuilder, *Streamer, SplitCU);
506506
} else {
507-
for (std::unique_ptr<llvm::DWARFUnit> &CU :
508-
SplitCU.getContext().dwo_compile_units())
509-
emitUnit(DWODIEBuilder, *Streamer, *CU);
507+
emitUnit(DWODIEBuilder, *Streamer, SplitCU);
510508

511509
// emit debug_types sections for dwarf4
512510
for (DWARFUnit *CU : DWODIEBuilder.getDWARF4TUVector())

0 commit comments

Comments
 (0)