mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-06-22 10:24:26 +00:00
DebugInfo: Sink accelerator table lists down (GlobalNames/Types) into DwarfCompileUnit
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@221083 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@ -694,5 +694,22 @@ void DwarfCompileUnit::emitHeader(const MCSymbol *ASectionSym) const {
|
||||
DwarfUnit::emitHeader(ASectionSym);
|
||||
}
|
||||
|
||||
/// addGlobalName - Add a new global name to the compile unit.
|
||||
void DwarfCompileUnit::addGlobalName(StringRef Name, DIE &Die,
|
||||
DIScope Context) {
|
||||
if (getCUNode().getEmissionKind() == DIBuilder::LineTablesOnly)
|
||||
return;
|
||||
std::string FullName = getParentContextString(Context) + Name.str();
|
||||
GlobalNames[FullName] = &Die;
|
||||
}
|
||||
|
||||
/// Add a new global type to the unit.
|
||||
void DwarfCompileUnit::addGlobalType(DIType Ty, const DIE &Die,
|
||||
DIScope Context) {
|
||||
if (getCUNode().getEmissionKind() == DIBuilder::LineTablesOnly)
|
||||
return;
|
||||
std::string FullName = getParentContextString(Context) + Ty.getName().str();
|
||||
GlobalTypes[FullName] = &Die;
|
||||
}
|
||||
|
||||
} // end llvm namespace
|
||||
|
Reference in New Issue
Block a user