summaryrefslogtreecommitdiff
path: root/lib/Transforms/Utils/CodeExtractor.cpp
diff options
context:
space:
mode:
authorAlkis Evlogimenos <alkis@evlogimenos.com>2004-05-26 22:50:28 +0000
committerAlkis Evlogimenos <alkis@evlogimenos.com>2004-05-26 22:50:28 +0000
commitfe3a093bc61ab11dd2c6c9e1e60f42f0a7ef48f3 (patch)
tree16888f9998e482fd9094949f4d07393992928f99 /lib/Transforms/Utils/CodeExtractor.cpp
parentf6e8cb495454119c371535e5402e6865b52ec445 (diff)
downloadllvm-fe3a093bc61ab11dd2c6c9e1e60f42f0a7ef48f3.tar.gz
llvm-fe3a093bc61ab11dd2c6c9e1e60f42f0a7ef48f3.tar.bz2
llvm-fe3a093bc61ab11dd2c6c9e1e60f42f0a7ef48f3.tar.xz
Do not pass a null pointer if this instruction is not prepended or
appended anywhere. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13798 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Transforms/Utils/CodeExtractor.cpp')
-rw-r--r--lib/Transforms/Utils/CodeExtractor.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/Transforms/Utils/CodeExtractor.cpp b/lib/Transforms/Utils/CodeExtractor.cpp
index 4d1093b739..cab281a7fc 100644
--- a/lib/Transforms/Utils/CodeExtractor.cpp
+++ b/lib/Transforms/Utils/CodeExtractor.cpp
@@ -394,7 +394,7 @@ emitCallAndSwitchStatement(Function *newFunction, BasicBlock *codeReplacer,
Indices.push_back(ConstantUInt::get(Type::UIntTy, i));
GetElementPtrInst *GEP =
new GetElementPtrInst(Struct, Indices,
- "gep_" + StructValues[i]->getName(), 0);
+ "gep_" + StructValues[i]->getName());
codeReplacer->getInstList().push_back(GEP);
StoreInst *SI = new StoreInst(StructValues[i], GEP);
codeReplacer->getInstList().push_back(SI);
@@ -420,7 +420,7 @@ emitCallAndSwitchStatement(Function *newFunction, BasicBlock *codeReplacer,
Indices.push_back(ConstantUInt::get(Type::UIntTy, FirstOut + i));
GetElementPtrInst *GEP
= new GetElementPtrInst(Struct, Indices,
- "gep_reload_" + outputs[i]->getName(), 0);
+ "gep_reload_" + outputs[i]->getName());
codeReplacer->getInstList().push_back(GEP);
Output = GEP;
} else {