summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Transforms/IPO/GlobalOpt.cpp
diff options
context:
space:
mode:
authorDavid Blaikie <dblaikie@gmail.com>2015-03-14 19:24:04 +0000
committerDavid Blaikie <dblaikie@gmail.com>2015-03-14 19:24:04 +0000
commit22319eb920bd9c113b8acf001abad44e84c1cfc4 (patch)
tree7e3b66c48a6a3126e2d4ad9588509e3bccf19e44 /llvm/lib/Transforms/IPO/GlobalOpt.cpp
parentbdae8d6403841650a9d73518a33b2ede8299404e (diff)
downloadbcm5719-llvm-22319eb920bd9c113b8acf001abad44e84c1cfc4.tar.gz
bcm5719-llvm-22319eb920bd9c113b8acf001abad44e84c1cfc4.zip
[opaque pointer type] more gep API migrations
Adding nullptr to all the IRBuilder stuff because it's the first thing that fails to build when testing without the back-compat functions, so I'll keep having to re-add these locally for each chunk of migration I do. Might as well check them in to save me the churn. Eventually I'll have to migrate these too, but I'm going breadth-first. llvm-svn: 232270
Diffstat (limited to 'llvm/lib/Transforms/IPO/GlobalOpt.cpp')
-rw-r--r--llvm/lib/Transforms/IPO/GlobalOpt.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/Transforms/IPO/GlobalOpt.cpp b/llvm/lib/Transforms/IPO/GlobalOpt.cpp
index 26dc9910b07..97e98bbd889 100644
--- a/llvm/lib/Transforms/IPO/GlobalOpt.cpp
+++ b/llvm/lib/Transforms/IPO/GlobalOpt.cpp
@@ -1221,7 +1221,7 @@ static void RewriteHeapSROALoadUser(Instruction *LoadUser,
GEPIdx.push_back(GEPI->getOperand(1));
GEPIdx.append(GEPI->op_begin()+3, GEPI->op_end());
- Value *NGEPI = GetElementPtrInst::Create(NewPtr, GEPIdx,
+ Value *NGEPI = GetElementPtrInst::Create(GEPI->getResultElementType(), NewPtr, GEPIdx,
GEPI->getName(), GEPI);
GEPI->replaceAllUsesWith(NGEPI);
GEPI->eraseFromParent();
OpenPOWER on IntegriCloud