summaryrefslogtreecommitdiffstats
path: root/llvm/lib/IR
diff options
context:
space:
mode:
Diffstat (limited to 'llvm/lib/IR')
-rw-r--r--llvm/lib/IR/DebugInfo.cpp14
1 files changed, 14 insertions, 0 deletions
diff --git a/llvm/lib/IR/DebugInfo.cpp b/llvm/lib/IR/DebugInfo.cpp
index 8ae2bcb8485..721fbc8c3a0 100644
--- a/llvm/lib/IR/DebugInfo.cpp
+++ b/llvm/lib/IR/DebugInfo.cpp
@@ -685,6 +685,20 @@ template <> DITypeRef DIDescriptor::getFieldAs<DITypeRef>(unsigned Elt) const {
return DITypeRef(cast_or_null<Metadata>(getField(DbgNode, Elt)));
}
+template <>
+DIDescriptor
+DIRef<DIDescriptor>::resolve(const DITypeIdentifierMap &Map) const {
+ return DIDescriptor(DebugNodeRef(Val).resolve(Map));
+}
+template <>
+DIScope DIRef<DIScope>::resolve(const DITypeIdentifierMap &Map) const {
+ return MDScopeRef(Val).resolve(Map);
+}
+template <>
+DIType DIRef<DIType>::resolve(const DITypeIdentifierMap &Map) const {
+ return MDTypeRef(Val).resolve(Map);
+}
+
bool llvm::stripDebugInfo(Function &F) {
bool Changed = false;
for (BasicBlock &BB : F) {
OpenPOWER on IntegriCloud