mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-01-22 10:33:23 +00:00
AsmPrinter: Take DIEValueList in some DwarfUnit API, NFC
Take `DIEValueList` instead of `DIE` so that `DIEBlock` and `DIELoc` can stop inheriting from `DIE` in a future commit. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@243855 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
bc3c2c319c
commit
69e4c2fc86
@ -192,18 +192,19 @@ void DwarfUnit::addFlag(DIE &Die, dwarf::Attribute Attribute) {
|
|||||||
DIEInteger(1));
|
DIEInteger(1));
|
||||||
}
|
}
|
||||||
|
|
||||||
void DwarfUnit::addUInt(DIE &Die, dwarf::Attribute Attribute,
|
void DwarfUnit::addUInt(DIEValueList &Die, dwarf::Attribute Attribute,
|
||||||
Optional<dwarf::Form> Form, uint64_t Integer) {
|
Optional<dwarf::Form> Form, uint64_t Integer) {
|
||||||
if (!Form)
|
if (!Form)
|
||||||
Form = DIEInteger::BestForm(false, Integer);
|
Form = DIEInteger::BestForm(false, Integer);
|
||||||
Die.addValue(DIEValueAllocator, Attribute, *Form, DIEInteger(Integer));
|
Die.addValue(DIEValueAllocator, Attribute, *Form, DIEInteger(Integer));
|
||||||
}
|
}
|
||||||
|
|
||||||
void DwarfUnit::addUInt(DIE &Block, dwarf::Form Form, uint64_t Integer) {
|
void DwarfUnit::addUInt(DIEValueList &Block, dwarf::Form Form,
|
||||||
|
uint64_t Integer) {
|
||||||
addUInt(Block, (dwarf::Attribute)0, Form, Integer);
|
addUInt(Block, (dwarf::Attribute)0, Form, Integer);
|
||||||
}
|
}
|
||||||
|
|
||||||
void DwarfUnit::addSInt(DIE &Die, dwarf::Attribute Attribute,
|
void DwarfUnit::addSInt(DIEValueList &Die, dwarf::Attribute Attribute,
|
||||||
Optional<dwarf::Form> Form, int64_t Integer) {
|
Optional<dwarf::Form> Form, int64_t Integer) {
|
||||||
if (!Form)
|
if (!Form)
|
||||||
Form = DIEInteger::BestForm(true, Integer);
|
Form = DIEInteger::BestForm(true, Integer);
|
||||||
@ -222,9 +223,10 @@ void DwarfUnit::addString(DIE &Die, dwarf::Attribute Attribute,
|
|||||||
DIEString(DU->getStringPool().getEntry(*Asm, String)));
|
DIEString(DU->getStringPool().getEntry(*Asm, String)));
|
||||||
}
|
}
|
||||||
|
|
||||||
DIE::value_iterator DwarfUnit::addLabel(DIE &Die, dwarf::Attribute Attribute,
|
DIEValueList::value_iterator DwarfUnit::addLabel(DIEValueList &Die,
|
||||||
dwarf::Form Form,
|
dwarf::Attribute Attribute,
|
||||||
const MCSymbol *Label) {
|
dwarf::Form Form,
|
||||||
|
const MCSymbol *Label) {
|
||||||
return Die.addValue(DIEValueAllocator, Attribute, Form, DIELabel(Label));
|
return Die.addValue(DIEValueAllocator, Attribute, Form, DIELabel(Label));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -186,14 +186,14 @@ public:
|
|||||||
void addFlag(DIE &Die, dwarf::Attribute Attribute);
|
void addFlag(DIE &Die, dwarf::Attribute Attribute);
|
||||||
|
|
||||||
/// Add an unsigned integer attribute data and value.
|
/// Add an unsigned integer attribute data and value.
|
||||||
void addUInt(DIE &Die, dwarf::Attribute Attribute, Optional<dwarf::Form> Form,
|
void addUInt(DIEValueList &Die, dwarf::Attribute Attribute,
|
||||||
uint64_t Integer);
|
Optional<dwarf::Form> Form, uint64_t Integer);
|
||||||
|
|
||||||
void addUInt(DIE &Block, dwarf::Form Form, uint64_t Integer);
|
void addUInt(DIEValueList &Block, dwarf::Form Form, uint64_t Integer);
|
||||||
|
|
||||||
/// Add an signed integer attribute data and value.
|
/// Add an signed integer attribute data and value.
|
||||||
void addSInt(DIE &Die, dwarf::Attribute Attribute, Optional<dwarf::Form> Form,
|
void addSInt(DIEValueList &Die, dwarf::Attribute Attribute,
|
||||||
int64_t Integer);
|
Optional<dwarf::Form> Form, int64_t Integer);
|
||||||
|
|
||||||
void addSInt(DIELoc &Die, Optional<dwarf::Form> Form, int64_t Integer);
|
void addSInt(DIELoc &Die, Optional<dwarf::Form> Form, int64_t Integer);
|
||||||
|
|
||||||
@ -206,8 +206,10 @@ public:
|
|||||||
void addString(DIE &Die, dwarf::Attribute Attribute, StringRef Str);
|
void addString(DIE &Die, dwarf::Attribute Attribute, StringRef Str);
|
||||||
|
|
||||||
/// Add a Dwarf label attribute data and value.
|
/// Add a Dwarf label attribute data and value.
|
||||||
DIE::value_iterator addLabel(DIE &Die, dwarf::Attribute Attribute,
|
DIEValueList::value_iterator addLabel(DIEValueList &Die,
|
||||||
dwarf::Form Form, const MCSymbol *Label);
|
dwarf::Attribute Attribute,
|
||||||
|
dwarf::Form Form,
|
||||||
|
const MCSymbol *Label);
|
||||||
|
|
||||||
void addLabel(DIELoc &Die, dwarf::Form Form, const MCSymbol *Label);
|
void addLabel(DIELoc &Die, dwarf::Form Form, const MCSymbol *Label);
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user