summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen/AsmPrinter/DwarfDebug.cpp
diff options
context:
space:
mode:
authorDevang Patel <dpatel@apple.com>2011-07-15 16:38:42 +0000
committerDevang Patel <dpatel@apple.com>2011-07-15 16:38:42 +0000
commitf5f352dda534ea676a2ddb00f8bc36dbd129974e (patch)
tree8a6426697fc1401e4d57c663425b3355106698bd /llvm/lib/CodeGen/AsmPrinter/DwarfDebug.cpp
parent57508026c276d9ffca1d84dfb74ea60c9b18b76a (diff)
downloadbcm5719-llvm-f5f352dda534ea676a2ddb00f8bc36dbd129974e.tar.gz
bcm5719-llvm-f5f352dda534ea676a2ddb00f8bc36dbd129974e.zip
Eliminate redundant map.
llvm-svn: 135278
Diffstat (limited to 'llvm/lib/CodeGen/AsmPrinter/DwarfDebug.cpp')
-rw-r--r--llvm/lib/CodeGen/AsmPrinter/DwarfDebug.cpp11
1 files changed, 3 insertions, 8 deletions
diff --git a/llvm/lib/CodeGen/AsmPrinter/DwarfDebug.cpp b/llvm/lib/CodeGen/AsmPrinter/DwarfDebug.cpp
index 03fb8d1fa31..c5efd99969a 100644
--- a/llvm/lib/CodeGen/AsmPrinter/DwarfDebug.cpp
+++ b/llvm/lib/CodeGen/AsmPrinter/DwarfDebug.cpp
@@ -1597,9 +1597,6 @@ DbgScope *DwarfDebug::getOrCreateDbgScope(DebugLoc DL) {
getOrCreateDbgScope(DebugLoc::getFromDILocation(InlinedAt));
WScope->setParent(Parent);
Parent->addScope(WScope);
-
- ConcreteScopes[InlinedAt] = WScope;
-
return WScope;
}
@@ -2049,7 +2046,6 @@ void DwarfDebug::endFunction(const MachineFunction *MF) {
DeleteContainerSeconds(DbgScopeMap);
UserVariables.clear();
DbgValues.clear();
- ConcreteScopes.clear();
DeleteContainerSeconds(AbstractScopes);
AbstractScopesList.clear();
AbstractVariables.clear();
@@ -2083,11 +2079,10 @@ DbgScope *DwarfDebug::findDbgScope(DebugLoc DL) {
DbgScope *Scope = NULL;
LLVMContext &Ctx = Asm->MF->getFunction()->getContext();
+ const MDNode *N = DL.getScope(Ctx);
if (const MDNode *IA = DL.getInlinedAt(Ctx))
- Scope = ConcreteScopes.lookup(IA);
- if (Scope == 0)
- Scope = DbgScopeMap.lookup(DL.getScope(Ctx));
-
+ N = IA;
+ Scope = DbgScopeMap.lookup(N);
return Scope;
}
OpenPOWER on IntegriCloud