[PATCH] D26567: Improve DWARF parsing speed by improving DWARFAbbreviationDeclaration
Adrian Prantl via llvm-commits
llvm-commits at lists.llvm.org
Fri Nov 11 15:48:01 PST 2016
aprantl added inline comments.
================
Comment at: include/llvm/DebugInfo/DWARF/DWARFDebugInfoEntry.h:50
/// doesn't change OffsetPtr.
- bool extractFast(const DWARFUnit *U, uint32_t *OffsetPtr);
+ bool extractFast(const DWARFUnit &U, uint32_t *OffsetPtr);
+ /// High performance extraction should use this call.
----------------
This is pointer to an offset in the section? Would a `uint32_t &` be more readable here? (Not sure since it is then less clear that this is an inout argument at the call site.)
================
Comment at: include/llvm/DebugInfo/DWARF/DWARFDebugInfoEntry.h:51
+ bool extractFast(const DWARFUnit &U, uint32_t *OffsetPtr);
+ /// High performance extraction should use this call.
+ bool extractFast(const DWARFUnit &U, uint32_t *OffsetPtr,
----------------
Why are there two methods called `extractFast`, is that a transitional thing that will go away in a subsequent patch?
That's a general problem I have even with the original interface: Just from looking at the documentation here it isn't clear to me what this function does and what the alternative to extractFast would be.
================
Comment at: tools/dsymutil/DwarfLinker.cpp:2085
if (!(Flags & TF_InFunctionScope) &&
- Abbrev->findAttributeIndex(dwarf::DW_AT_const_value) != -1U) {
+ Abbrev->findAttributeIndex(dwarf::DW_AT_const_value)) {
MyInfo.InDebugMap = true;
----------------
Much nicer!
https://reviews.llvm.org/D26567
More information about the llvm-commits
mailing list