mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-06-26 07:24:25 +00:00
Use dwarf::Tag rather than unsigned for DIE::Tag to make debugging easier.
Nice to be able to just print out the Tag and have the debugger print dwarf::DW_TAG_subprogram or whatever, rather than an int. It's a bit finicky (for example DIDescriptor::getTag still returns unsigned) because some places still handle real dwarf tags + our fake tags (one day we'll remove the fake tags, hopefully). git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@206098 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@ -791,8 +791,7 @@ void DwarfDebug::constructImportedEntityDIE(DwarfCompileUnit *TheCU,
|
||||
assert(Module.Verify() &&
|
||||
"Use one of the MDNode * overloads to handle invalid metadata");
|
||||
assert(Context && "Should always have a context for an imported_module");
|
||||
DIE *IMDie = new DIE(Module.getTag());
|
||||
TheCU->insertDIE(Module, IMDie);
|
||||
DIE *IMDie = TheCU->createAndAddDIE(Module.getTag(), *Context, Module);
|
||||
DIE *EntityDie;
|
||||
DIDescriptor Entity = resolve(Module.getEntity());
|
||||
if (Entity.isNameSpace())
|
||||
@ -810,7 +809,6 @@ void DwarfDebug::constructImportedEntityDIE(DwarfCompileUnit *TheCU,
|
||||
StringRef Name = Module.getName();
|
||||
if (!Name.empty())
|
||||
TheCU->addString(IMDie, dwarf::DW_AT_name, Name);
|
||||
Context->addChild(IMDie);
|
||||
}
|
||||
|
||||
// Emit all Dwarf sections that should come prior to the content. Create
|
||||
|
Reference in New Issue
Block a user