summaryrefslogtreecommitdiffstats
path: root/llvm/lib/IR/Verifier.cpp
diff options
context:
space:
mode:
authorManman Ren <manman.ren@gmail.com>2013-11-17 18:42:37 +0000
committerManman Ren <manman.ren@gmail.com>2013-11-17 18:42:37 +0000
commit2085cccf99517f34130f3853319ee154e03fdb26 (patch)
treec573b5d14b5e0a7d53ed78d7abf4afbbeecd84d8 /llvm/lib/IR/Verifier.cpp
parent02413d88f15df9766ea66829804273f64b883d28 (diff)
downloadbcm5719-llvm-2085cccf99517f34130f3853319ee154e03fdb26.tar.gz
bcm5719-llvm-2085cccf99517f34130f3853319ee154e03fdb26.zip
Debug Info Verifier: enable public functions of Finder to update the type map.
We used to depend on running processModule before the other public functions such as processDeclare, processValue and processLocation. We are now relaxing the constraint by adding a module argument to the three functions and letting the three functions to initialize the type map. This will be used in a follow-on patch that collects nodes reachable from a Function. llvm-svn: 194973
Diffstat (limited to 'llvm/lib/IR/Verifier.cpp')
-rw-r--r--llvm/lib/IR/Verifier.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/llvm/lib/IR/Verifier.cpp b/llvm/lib/IR/Verifier.cpp
index 8ce48bed28f..32acfbd9ccc 100644
--- a/llvm/lib/IR/Verifier.cpp
+++ b/llvm/lib/IR/Verifier.cpp
@@ -2125,7 +2125,7 @@ void Verifier::visitInstruction(Instruction &I) {
if (!DisableDebugInfoVerifier) {
MD = I.getMetadata(LLVMContext::MD_dbg);
- Finder.processLocation(DILocation(MD));
+ Finder.processLocation(*Mod, DILocation(MD));
}
InstsInThisBlock.insert(&I);
@@ -2303,13 +2303,13 @@ void Verifier::visitIntrinsicFunctionCall(Intrinsic::ID ID, CallInst &CI) {
Assert1(MD->getNumOperands() == 1,
"invalid llvm.dbg.declare intrinsic call 2", &CI);
if (!DisableDebugInfoVerifier)
- Finder.processDeclare(cast<DbgDeclareInst>(&CI));
+ Finder.processDeclare(*Mod, cast<DbgDeclareInst>(&CI));
} break;
case Intrinsic::dbg_value: { //llvm.dbg.value
if (!DisableDebugInfoVerifier) {
Assert1(CI.getArgOperand(0) && isa<MDNode>(CI.getArgOperand(0)),
"invalid llvm.dbg.value intrinsic call 1", &CI);
- Finder.processValue(cast<DbgValueInst>(&CI));
+ Finder.processValue(*Mod, cast<DbgValueInst>(&CI));
}
break;
}
OpenPOWER on IntegriCloud