mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-07-24 22:24:54 +00:00
Rewrite llvm-pdbdump in terms of LLVMDebugInfoPDB.
This makes llvm-pdbdump available on all platforms, although it will currently fail to create a dumper if there is no PDB reader implementation for the current platform. It implements dumping of compilands and children, which is less information than was previously available, but it has to be rewritten from scratch using the new set of interfaces, so the rest of the functionality will be added back in subsequent commits. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@228755 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -98,10 +98,17 @@ PDBSymbol::create(const IPDBSession &PDBSession,
|
||||
}
|
||||
}
|
||||
|
||||
void PDBSymbol::dump(llvm::raw_ostream &OS) const { RawSymbol->dump(OS); }
|
||||
void PDBSymbol::defaultDump(raw_ostream &OS, int Indent,
|
||||
PDB_DumpLevel Level) const {
|
||||
RawSymbol->dump(OS, Indent, Level);
|
||||
}
|
||||
|
||||
PDB_SymType PDBSymbol::getSymTag() const { return RawSymbol->getSymTag(); }
|
||||
|
||||
std::unique_ptr<IPDBEnumSymbols> PDBSymbol::findChildren(PDB_SymType Type) const {
|
||||
return RawSymbol->findChildren(Type);
|
||||
}
|
||||
|
||||
std::unique_ptr<IPDBEnumSymbols>
|
||||
PDBSymbol::findChildren(PDB_SymType Type, StringRef Name,
|
||||
PDB_NameSearchFlags Flags) const {
|
||||
@@ -118,3 +125,14 @@ std::unique_ptr<IPDBEnumSymbols>
|
||||
PDBSymbol::findInlineFramesByRVA(uint32_t RVA) const {
|
||||
return RawSymbol->findInlineFramesByRVA(RVA);
|
||||
}
|
||||
|
||||
std::unique_ptr<IPDBEnumSymbols>
|
||||
PDBSymbol::getChildStats(TagStats &Stats) const {
|
||||
std::unique_ptr<IPDBEnumSymbols> Result(findChildren(PDB_SymType::None));
|
||||
Stats.clear();
|
||||
while (auto Child = Result->getNext()) {
|
||||
++Stats[Child->getSymTag()];
|
||||
}
|
||||
Result->reset();
|
||||
return Result;
|
||||
}
|
||||
|
Reference in New Issue
Block a user