summaryrefslogtreecommitdiff
path: root/lib/CodeGen
diff options
context:
space:
mode:
authorDavid Blaikie <dblaikie@gmail.com>2013-05-07 17:57:13 +0000
committerDavid Blaikie <dblaikie@gmail.com>2013-05-07 17:57:13 +0000
commit498c91e341ff8cff835b053c25a76fe7c21b06a9 (patch)
tree25acdbf5f282f8d51fa852465aa98c18988f156c /lib/CodeGen
parent8a88cadaedcfa3bb020df1d100d67cecaf638f35 (diff)
downloadllvm-498c91e341ff8cff835b053c25a76fe7c21b06a9.tar.gz
llvm-498c91e341ff8cff835b053c25a76fe7c21b06a9.tar.bz2
llvm-498c91e341ff8cff835b053c25a76fe7c21b06a9.tar.xz
Debug Info: Fix for break due to r181271
Apparently we didn't keep an association of Compile Unit metadata nodes to DIEs so looking up that parental context failed & thus caused no DW_TAG_imported_modules to be emitted at the CU scope. Fix this by adding the mapping & sure up the test case to verify this. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@181339 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen')
-rw-r--r--lib/CodeGen/AsmPrinter/DwarfDebug.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/CodeGen/AsmPrinter/DwarfDebug.cpp b/lib/CodeGen/AsmPrinter/DwarfDebug.cpp
index aeaa63f2af..90dceacb79 100644
--- a/lib/CodeGen/AsmPrinter/DwarfDebug.cpp
+++ b/lib/CodeGen/AsmPrinter/DwarfDebug.cpp
@@ -685,6 +685,7 @@ CompileUnit *DwarfDebug::constructCompileUnit(const MDNode *N) {
CompileUnit *NewCU = new CompileUnit(GlobalCUIndexCount++,
DIUnit.getLanguage(), Die, Asm,
this, &InfoHolder);
+ NewCU->insertDIE(N, Die);
FileIDCUMap[NewCU->getUniqueID()] = 0;
// Call this to emit a .file directive if it wasn't emitted for the source