[llvm-commits] [poolalloc] r130908 - in /poolalloc/trunk: include/assistDS/TypeChecks.h lib/AssistDS/TypeChecks.cpp
Arushi Aggarwal
aggarwa4 at illinois.edu
Wed May 4 18:47:38 PDT 2011
Author: aggarwa4
Date: Wed May 4 20:47:38 2011
New Revision: 130908
URL: http://llvm.org/viewvc/llvm-project?rev=130908&view=rev
Log:
Also handle Invoke Insts.
Modified:
poolalloc/trunk/include/assistDS/TypeChecks.h
poolalloc/trunk/lib/AssistDS/TypeChecks.cpp
Modified: poolalloc/trunk/include/assistDS/TypeChecks.h
URL: http://llvm.org/viewvc/llvm-project/poolalloc/trunk/include/assistDS/TypeChecks.h?rev=130908&r1=130907&r2=130908&view=diff
==============================================================================
--- poolalloc/trunk/include/assistDS/TypeChecks.h (original)
+++ poolalloc/trunk/include/assistDS/TypeChecks.h Wed May 4 20:47:38 2011
@@ -57,11 +57,12 @@
bool initShadow(Module &M, Instruction &I);
bool unmapShadow(Module &M, Instruction &I);
bool visitCallInst(Module &M, CallInst &CI);
+ bool visitInvokeInst(Module &M, InvokeInst &CI);
bool visitCallSite(Module &M, CallSite CS);
bool visitLoadInst(Module &M, LoadInst &LI);
+ bool visitStoreInst(Module &M, StoreInst &SI);
bool visitGlobal(Module &M, GlobalVariable &GV,
Constant *C, Instruction &I, unsigned offset);
- bool visitStoreInst(Module &M, StoreInst &SI);
bool visitCopyingStoreInst(Module &M, StoreInst &SI, Value *SS);
bool visitInputFunctionValue(Module &M, Value *V, Instruction *CI);
Modified: poolalloc/trunk/lib/AssistDS/TypeChecks.cpp
URL: http://llvm.org/viewvc/llvm-project/poolalloc/trunk/lib/AssistDS/TypeChecks.cpp?rev=130908&r1=130907&r2=130908&view=diff
==============================================================================
--- poolalloc/trunk/lib/AssistDS/TypeChecks.cpp (original)
+++ poolalloc/trunk/lib/AssistDS/TypeChecks.cpp Wed May 4 20:47:38 2011
@@ -133,6 +133,9 @@
}
} else if (CallInst *CI = dyn_cast<CallInst>(&I)) {
modified |= visitCallInst(M, *CI);
+ } else if (InvokeInst *II = dyn_cast<InvokeInst>(&I)) {
+ II->dump();
+ modified |= visitInvokeInst(M, *II);
}
}
}
@@ -276,6 +279,11 @@
return visitCallSite(M, &CI);
}
+// Insert runtime checks for certain call instructions
+bool TypeChecks::visitInvokeInst(Module &M, InvokeInst &II) {
+ return visitCallSite(M, &II);
+}
+
bool TypeChecks::visitCallSite(Module &M, CallSite CS) {
//
// Get the called value. Strip off any casts which are lossless.
More information about the llvm-commits
mailing list