aboutsummaryrefslogtreecommitdiff
path: root/lib/Analysis/ScalarEvolution.cpp
diff options
context:
space:
mode:
authorDan Gohman <gohman@apple.com>2009-05-08 20:36:47 +0000
committerDan Gohman <gohman@apple.com>2009-05-08 20:36:47 +0000
commite810b0d430d989545094cfd080fcd8038f9b31a3 (patch)
treecd65ef5565cb18687a944e6b94e7cfd7be4c8075 /lib/Analysis/ScalarEvolution.cpp
parentad9c278338089abef904954670f25d53a8c7bcfe (diff)
Fix an error from r71252.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@71255 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Analysis/ScalarEvolution.cpp')
-rw-r--r--lib/Analysis/ScalarEvolution.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/Analysis/ScalarEvolution.cpp b/lib/Analysis/ScalarEvolution.cpp
index 81bf7e8dd9..c43aad3987 100644
--- a/lib/Analysis/ScalarEvolution.cpp
+++ b/lib/Analysis/ScalarEvolution.cpp
@@ -1869,11 +1869,11 @@ SCEVHandle ScalarEvolution::createNodeForPHI(PHINode *PN) {
SCEVHandle ScalarEvolution::createNodeForGEP(GetElementPtrInst *GEP) {
const Type *IntPtrTy = TD->getIntPtrType();
- Value *Base = U->getOperand(0);
+ Value *Base = GEP->getOperand(0);
SCEVHandle TotalOffset = getIntegerSCEV(0, IntPtrTy);
- gep_type_iterator GTI = gep_type_begin(U);
- for (GetElementPtrInst::op_iterator I = next(U->op_begin()),
- E = U->op_end();
+ gep_type_iterator GTI = gep_type_begin(GEP);
+ for (GetElementPtrInst::op_iterator I = next(GEP->op_begin()),
+ E = GEP->op_end();
I != E; ++I) {
Value *Index = *I;
// Compute the (potentially symbolic) offset in bytes for this index.