mirror of
https://github.com/RPCS3/llvm.git
synced 2025-01-10 22:46:25 +00:00
Sink DwarfUnit::CURanges into DwarfCompileUnit
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@221161 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
e13ea1ddda
commit
60b9b0d581
@ -52,6 +52,9 @@ class DwarfCompileUnit : public DwarfUnit {
|
|||||||
// the CU itself.
|
// the CU itself.
|
||||||
SmallVector<RangeSpanList, 1> CURangeLists;
|
SmallVector<RangeSpanList, 1> CURangeLists;
|
||||||
|
|
||||||
|
// List of ranges for a given compile unit.
|
||||||
|
SmallVector<RangeSpan, 1> CURanges;
|
||||||
|
|
||||||
/// \brief Construct a DIE for the given DbgVariable without initializing the
|
/// \brief Construct a DIE for the given DbgVariable without initializing the
|
||||||
/// DbgVariable's DIE reference.
|
/// DbgVariable's DIE reference.
|
||||||
std::unique_ptr<DIE> constructVariableDIEImpl(const DbgVariable &DV,
|
std::unique_ptr<DIE> constructVariableDIEImpl(const DbgVariable &DV,
|
||||||
@ -233,6 +236,9 @@ public:
|
|||||||
return CURangeLists;
|
return CURangeLists;
|
||||||
}
|
}
|
||||||
SmallVectorImpl<RangeSpanList> &getRangeLists() { return CURangeLists; }
|
SmallVectorImpl<RangeSpanList> &getRangeLists() { return CURangeLists; }
|
||||||
|
|
||||||
|
/// getRanges - Get the list of ranges for this unit.
|
||||||
|
const SmallVectorImpl<RangeSpan> &getRanges() const { return CURanges; }
|
||||||
};
|
};
|
||||||
|
|
||||||
} // end llvm namespace
|
} // end llvm namespace
|
||||||
|
@ -591,7 +591,7 @@ void DwarfDebug::finalizeModuleInfo() {
|
|||||||
// 2.17.3).
|
// 2.17.3).
|
||||||
U.addUInt(U.getUnitDie(), dwarf::DW_AT_low_pc, dwarf::DW_FORM_addr, 0);
|
U.addUInt(U.getUnitDie(), dwarf::DW_AT_low_pc, dwarf::DW_FORM_addr, 0);
|
||||||
} else {
|
} else {
|
||||||
RangeSpan &Range = TheCU.getRanges().back();
|
const RangeSpan &Range = TheCU.getRanges().back();
|
||||||
U.attachLowHighPC(U.getUnitDie(), Range.getStart(), Range.getEnd());
|
U.attachLowHighPC(U.getUnitDie(), Range.getStart(), Range.getEnd());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -107,9 +107,6 @@ protected:
|
|||||||
/// corresponds to the MDNode mapped with the subprogram DIE.
|
/// corresponds to the MDNode mapped with the subprogram DIE.
|
||||||
DenseMap<DIE *, const MDNode *> ContainingTypeMap;
|
DenseMap<DIE *, const MDNode *> ContainingTypeMap;
|
||||||
|
|
||||||
// List of ranges for a given compile unit.
|
|
||||||
SmallVector<RangeSpan, 1> CURanges;
|
|
||||||
|
|
||||||
// DIEValueAllocator - All DIEValues are allocated through this allocator.
|
// DIEValueAllocator - All DIEValues are allocated through this allocator.
|
||||||
BumpPtrAllocator DIEValueAllocator;
|
BumpPtrAllocator DIEValueAllocator;
|
||||||
|
|
||||||
@ -149,10 +146,6 @@ public:
|
|||||||
/// hasContent - Return true if this compile unit has something to write out.
|
/// hasContent - Return true if this compile unit has something to write out.
|
||||||
bool hasContent() const { return !UnitDie.getChildren().empty(); }
|
bool hasContent() const { return !UnitDie.getChildren().empty(); }
|
||||||
|
|
||||||
/// getRanges - Get the list of ranges for this unit.
|
|
||||||
const SmallVectorImpl<RangeSpan> &getRanges() const { return CURanges; }
|
|
||||||
SmallVectorImpl<RangeSpan> &getRanges() { return CURanges; }
|
|
||||||
|
|
||||||
/// getParentContextString - Get a string containing the language specific
|
/// getParentContextString - Get a string containing the language specific
|
||||||
/// context for a global name.
|
/// context for a global name.
|
||||||
std::string getParentContextString(DIScope Context) const;
|
std::string getParentContextString(DIScope Context) const;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user