mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-02-11 11:34:02 +00:00
Sink DwarfUnit::LabelBegin down into DwarfCompileUnit since that's the only place it's needed.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@221075 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
58913d5727
commit
da53f1e088
@ -39,6 +39,9 @@ class DwarfCompileUnit : public DwarfUnit {
|
|||||||
/// A label at the start of the non-dwo section related to this unit.
|
/// A label at the start of the non-dwo section related to this unit.
|
||||||
MCSymbol *SectionSym;
|
MCSymbol *SectionSym;
|
||||||
|
|
||||||
|
/// The start of the unit within its section.
|
||||||
|
MCSymbol *LabelBegin;
|
||||||
|
|
||||||
/// \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,
|
||||||
@ -171,6 +174,8 @@ public:
|
|||||||
void initSection(const MCSection *Section, MCSymbol *SectionSym) {
|
void initSection(const MCSection *Section, MCSymbol *SectionSym) {
|
||||||
DwarfUnit::initSection(Section);
|
DwarfUnit::initSection(Section);
|
||||||
this->SectionSym = SectionSym;
|
this->SectionSym = SectionSym;
|
||||||
|
LabelBegin =
|
||||||
|
Asm->GetTempSymbol(Section->getLabelBeginName(), getUniqueID());
|
||||||
}
|
}
|
||||||
|
|
||||||
unsigned getLength() {
|
unsigned getLength() {
|
||||||
@ -179,6 +184,11 @@ public:
|
|||||||
}
|
}
|
||||||
|
|
||||||
void emitHeader(const MCSymbol *ASectionSym) const override;
|
void emitHeader(const MCSymbol *ASectionSym) const override;
|
||||||
|
|
||||||
|
MCSymbol *getLabelBegin() const {
|
||||||
|
assert(Section);
|
||||||
|
return LabelBegin;
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
} // end llvm namespace
|
} // end llvm namespace
|
||||||
|
@ -1752,8 +1752,6 @@ void DwarfUnit::emitHeader(const MCSymbol *ASectionSym) const {
|
|||||||
void DwarfUnit::initSection(const MCSection *Section) {
|
void DwarfUnit::initSection(const MCSection *Section) {
|
||||||
assert(!this->Section);
|
assert(!this->Section);
|
||||||
this->Section = Section;
|
this->Section = Section;
|
||||||
this->LabelBegin =
|
|
||||||
Asm->GetTempSymbol(Section->getLabelBeginName(), getUniqueID());
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void DwarfTypeUnit::emitHeader(const MCSymbol *ASectionSym) const {
|
void DwarfTypeUnit::emitHeader(const MCSymbol *ASectionSym) const {
|
||||||
|
@ -129,9 +129,6 @@ protected:
|
|||||||
/// The section this unit will be emitted in.
|
/// The section this unit will be emitted in.
|
||||||
const MCSection *Section;
|
const MCSection *Section;
|
||||||
|
|
||||||
/// The start of the unit within its section.
|
|
||||||
MCSymbol *LabelBegin;
|
|
||||||
|
|
||||||
DwarfUnit(unsigned UID, dwarf::Tag, DICompileUnit CU, AsmPrinter *A,
|
DwarfUnit(unsigned UID, dwarf::Tag, DICompileUnit CU, AsmPrinter *A,
|
||||||
DwarfDebug *DW, DwarfFile *DWU);
|
DwarfDebug *DW, DwarfFile *DWU);
|
||||||
|
|
||||||
@ -144,11 +141,6 @@ public:
|
|||||||
return Section;
|
return Section;
|
||||||
}
|
}
|
||||||
|
|
||||||
MCSymbol *getLabelBegin() const {
|
|
||||||
assert(Section);
|
|
||||||
return LabelBegin;
|
|
||||||
}
|
|
||||||
|
|
||||||
// Accessors.
|
// Accessors.
|
||||||
unsigned getUniqueID() const { return UniqueID; }
|
unsigned getUniqueID() const { return UniqueID; }
|
||||||
uint16_t getLanguage() const { return CUNode.getLanguage(); }
|
uint16_t getLanguage() const { return CUNode.getLanguage(); }
|
||||||
|
Loading…
x
Reference in New Issue
Block a user