diff options
author | Eric Christopher <echristo@gmail.com> | 2019-12-12 17:55:41 -0800 |
---|---|---|
committer | Eric Christopher <echristo@gmail.com> | 2019-12-12 17:55:41 -0800 |
commit | a8154e5e0c83d2f0f65f3b4fb1a0bc68785bd975 (patch) | |
tree | 5101677fad8b6921d59bed61503635b156ad5204 /llvm/lib/CodeGen/AsmPrinter/DwarfFile.h | |
parent | cdb45605571202a1bbc3fe6de300b93da79cea83 (diff) | |
download | bcm5719-llvm-a8154e5e0c83d2f0f65f3b4fb1a0bc68785bd975.tar.gz bcm5719-llvm-a8154e5e0c83d2f0f65f3b4fb1a0bc68785bd975.zip |
Temporarily revert "NFC: DebugInfo: Refactor RangeSpanList to be a struct, like DebugLocStream::List"
as it was causing bot and build failures.
This reverts commit 8e04896288d22ed8bef7ac367923374f96b753d6.
Diffstat (limited to 'llvm/lib/CodeGen/AsmPrinter/DwarfFile.h')
-rw-r--r-- | llvm/lib/CodeGen/AsmPrinter/DwarfFile.h | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/llvm/lib/CodeGen/AsmPrinter/DwarfFile.h b/llvm/lib/CodeGen/AsmPrinter/DwarfFile.h index cf293d7534d..35fa51fb24c 100644 --- a/llvm/lib/CodeGen/AsmPrinter/DwarfFile.h +++ b/llvm/lib/CodeGen/AsmPrinter/DwarfFile.h @@ -37,12 +37,21 @@ struct RangeSpan { const MCSymbol *End; }; -struct RangeSpanList { +class RangeSpanList { +private: // Index for locating within the debug_range section this particular span. - MCSymbol *Label; + MCSymbol *RangeSym; const DwarfCompileUnit *CU; // List of ranges. SmallVector<RangeSpan, 2> Ranges; + +public: + RangeSpanList(MCSymbol *Sym, const DwarfCompileUnit &CU, + SmallVector<RangeSpan, 2> Ranges) + : RangeSym(Sym), CU(&CU), Ranges(std::move(Ranges)) {} + MCSymbol *getSym() const { return RangeSym; } + const DwarfCompileUnit &getCU() const { return *CU; } + const SmallVectorImpl<RangeSpan> &getRanges() const { return Ranges; } }; class DwarfFile { |