summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Transforms/IPO/IndMemRemoval.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'llvm/lib/Transforms/IPO/IndMemRemoval.cpp')
-rw-r--r--llvm/lib/Transforms/IPO/IndMemRemoval.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/llvm/lib/Transforms/IPO/IndMemRemoval.cpp b/llvm/lib/Transforms/IPO/IndMemRemoval.cpp
index c993f70cec0..0779a5414f5 100644
--- a/llvm/lib/Transforms/IPO/IndMemRemoval.cpp
+++ b/llvm/lib/Transforms/IPO/IndMemRemoval.cpp
@@ -74,7 +74,8 @@ bool IndMemRemPass::runOnModule(Module &M) {
GlobalValue::LinkOnceLinkage,
"malloc_llvm_bounce", &M);
BasicBlock* bb = new BasicBlock("entry",FN);
- Instruction* c = new CastInst(FN->arg_begin(), Type::UIntTy, "c", bb);
+ Instruction* c =
+ CastInst::createInferredCast(FN->arg_begin(), Type::UIntTy, "c", bb);
Instruction* a = new MallocInst(Type::SByteTy, c, "m", bb);
new ReturnInst(a, bb);
++NumBounce;
OpenPOWER on IntegriCloud