mirror of
https://github.com/RPCS3/llvm.git
synced 2025-01-01 09:18:30 +00:00
DwarfAccelTable: Remove trivial dtor and simplify construction with an array.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@207044 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
e45bc94232
commit
e69ea7d8ae
@ -29,8 +29,6 @@ DwarfAccelTable::DwarfAccelTable(ArrayRef<DwarfAccelTable::Atom> atomList)
|
|||||||
: Header(8 + (atomList.size() * 4)), HeaderData(atomList),
|
: Header(8 + (atomList.size() * 4)), HeaderData(atomList),
|
||||||
Entries(Allocator) {}
|
Entries(Allocator) {}
|
||||||
|
|
||||||
DwarfAccelTable::~DwarfAccelTable() {}
|
|
||||||
|
|
||||||
void DwarfAccelTable::AddName(StringRef Name, const DIE *die, char Flags) {
|
void DwarfAccelTable::AddName(StringRef Name, const DIE *die, char Flags) {
|
||||||
assert(Data.empty() && "Already finalized!");
|
assert(Data.empty() && "Already finalized!");
|
||||||
// If the string is in the list already then add this die to the list
|
// If the string is in the list already then add this die to the list
|
||||||
|
@ -238,7 +238,6 @@ private:
|
|||||||
// Public Implementation
|
// Public Implementation
|
||||||
public:
|
public:
|
||||||
DwarfAccelTable(ArrayRef<DwarfAccelTable::Atom>);
|
DwarfAccelTable(ArrayRef<DwarfAccelTable::Atom>);
|
||||||
~DwarfAccelTable();
|
|
||||||
void AddName(StringRef, const DIE *, char = 0);
|
void AddName(StringRef, const DIE *, char = 0);
|
||||||
void FinalizeTable(AsmPrinter *, StringRef);
|
void FinalizeTable(AsmPrinter *, StringRef);
|
||||||
void Emit(AsmPrinter *, MCSymbol *, DwarfFile *);
|
void Emit(AsmPrinter *, MCSymbol *, DwarfFile *);
|
||||||
|
@ -1923,13 +1923,10 @@ void DwarfDebug::emitAccelNamespaces() {
|
|||||||
|
|
||||||
// Emit type dies into a hashed accelerator table.
|
// Emit type dies into a hashed accelerator table.
|
||||||
void DwarfDebug::emitAccelTypes() {
|
void DwarfDebug::emitAccelTypes() {
|
||||||
std::vector<DwarfAccelTable::Atom> Atoms;
|
DwarfAccelTable::Atom Atoms[] = {
|
||||||
Atoms.push_back(
|
DwarfAccelTable::Atom(dwarf::DW_ATOM_die_offset, dwarf::DW_FORM_data4),
|
||||||
DwarfAccelTable::Atom(dwarf::DW_ATOM_die_offset, dwarf::DW_FORM_data4));
|
DwarfAccelTable::Atom(dwarf::DW_ATOM_die_tag, dwarf::DW_FORM_data2),
|
||||||
Atoms.push_back(
|
DwarfAccelTable::Atom(dwarf::DW_ATOM_type_flags, dwarf::DW_FORM_data1)};
|
||||||
DwarfAccelTable::Atom(dwarf::DW_ATOM_die_tag, dwarf::DW_FORM_data2));
|
|
||||||
Atoms.push_back(
|
|
||||||
DwarfAccelTable::Atom(dwarf::DW_ATOM_type_flags, dwarf::DW_FORM_data1));
|
|
||||||
DwarfAccelTable AT(Atoms);
|
DwarfAccelTable AT(Atoms);
|
||||||
for (const auto &TheU : getUnits()) {
|
for (const auto &TheU : getUnits()) {
|
||||||
for (const auto &GI : TheU->getAccelTypes()) {
|
for (const auto &GI : TheU->getAccelTypes()) {
|
||||||
|
Loading…
Reference in New Issue
Block a user