[llvm] [LLVM][DebugInfo] Refactor some code for easier sharing. (PR #82153)
David Blaikie via llvm-commits
llvm-commits at lists.llvm.org
Mon Mar 18 15:51:19 PDT 2024
================
@@ -552,32 +552,50 @@ DWARFDebugNames::NameIndex::extractAbbrev(uint64_t *Offset) {
return Abbrev(Code, dwarf::Tag(Tag), AbbrevOffset, std::move(*AttrEncOr));
}
+void llvm::findDebugNamesOffsets(
+ DWARFDebugNames::DWARFDebugNamesOffsets &Offsets, uint64_t HdrSize,
+ dwarf::DwarfFormat Format, const DWARFDebugNames::Header &Hdr) {
+ uint32_t DwarfSize = (Format == llvm::dwarf::DwarfFormat::DWARF64) ? 8 : 4;
----------------
dwblaikie wrote:
This should use `dwarf::getDwarfOffsetByteSize`
https://github.com/llvm/llvm-project/pull/82153
More information about the llvm-commits
mailing list