summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 2982c08)
raw | patch | inline | side by side (parent: 2982c08)
author | Manman Ren <manman.ren@gmail.com> | |
Sat, 24 Aug 2013 00:32:12 +0000 (00:32 +0000) | ||
committer | Manman Ren <manman.ren@gmail.com> | |
Sat, 24 Aug 2013 00:32:12 +0000 (00:32 +0000) |
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@189158 91177308-0d34-0410-b5e6-96231b3b80d8
lib/IR/DebugInfo.cpp | patch | blob | history |
diff --git a/lib/IR/DebugInfo.cpp b/lib/IR/DebugInfo.cpp
index de3360129a50265bbc1e28600f91228da47e82a3..fdd8d537ce4d25fadf93b710a859268a371540ee 100644 (file)
--- a/lib/IR/DebugInfo.cpp
+++ b/lib/IR/DebugInfo.cpp
DIArray RetainedTypes = CU.getRetainedTypes();
for (unsigned i = 0, e = RetainedTypes.getNumElements(); i != e; ++i)
processType(DIType(RetainedTypes.getElement(i)));
+ DIArray Imports = CU.getImportedEntities();
+ for (unsigned i = 0, e = Imports.getNumElements(); i != e; ++i) {
+ DIImportedEntity Import = DIImportedEntity(
+ Imports.getElement(i));
+ DIDescriptor Entity = Import.getEntity();
+ if (Entity.isType())
+ processType(DIType(Entity));
+ else if (Entity.isSubprogram())
+ processSubprogram(DISubprogram(Entity));
+ else if (Entity.isNameSpace())
+ processScope(DINameSpace(Entity).getContext());
+ }
// FIXME: We really shouldn't be bailing out after visiting just one CU
return;
}