[PATCH] D155031: [BOLT][DWARF][NFC] Set initial offset of DIE
Alexander Yermolovich via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Jul 11 16:50:56 PDT 2023
ayermolo created this revision.
Herald added subscribers: treapster, hoy, modimo, wenlei.
Herald added a reviewer: rafauler.
Herald added a reviewer: Amir.
Herald added a reviewer: maksfb.
Herald added a project: All.
ayermolo requested review of this revision.
Herald added subscribers: llvm-commits, yota9.
Herald added a project: LLVM.
Setting initial offset of DIE to input DIE. This is to make "printf" debugging
easier.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D155031
Files:
bolt/lib/Core/DIEBuilder.cpp
Index: bolt/lib/Core/DIEBuilder.cpp
===================================================================
--- bolt/lib/Core/DIEBuilder.cpp
+++ bolt/lib/Core/DIEBuilder.cpp
@@ -290,6 +290,10 @@
DIEInfo &DieInfo = getDIEInfo(UnitId, *Idx);
uint64_t Offset = DDie.getOffset();
+ // Just for making debugging easier.
+ // DIE dump is not very useful.
+ // It's nice to know original offset from which this DIE was constructed.
+ DieInfo.Die->setOffset(Offset);
uint64_t NextOffset = Offset;
DWARFDataExtractor Data = U.getDebugInfoExtractor();
DWARFDebugInfoEntry DDIEntry;
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D155031.539341.patch
Type: text/x-patch
Size: 589 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20230711/a2b195d3/attachment.bin>
More information about the llvm-commits
mailing list