diff options
author | Manman Ren <manman.ren@gmail.com> | 2013-11-17 18:42:37 +0000 |
---|---|---|
committer | Manman Ren <manman.ren@gmail.com> | 2013-11-17 18:42:37 +0000 |
commit | 2b31b8227fb5507c26a8c4724574fc87fb90f482 (patch) | |
tree | 75287f174692aad37b0a2511e2ace212855bbb01 /lib/IR/Verifier.cpp | |
parent | 80ccd9ea59b8911f12836da98aceedce4ebc6a6f (diff) | |
download | external_llvm-2b31b8227fb5507c26a8c4724574fc87fb90f482.zip external_llvm-2b31b8227fb5507c26a8c4724574fc87fb90f482.tar.gz external_llvm-2b31b8227fb5507c26a8c4724574fc87fb90f482.tar.bz2 |
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.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@194973 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/IR/Verifier.cpp')
-rw-r--r-- | lib/IR/Verifier.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/IR/Verifier.cpp b/lib/IR/Verifier.cpp index 8ce48be..32acfbd 100644 --- a/lib/IR/Verifier.cpp +++ b/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; } |