Convert TargetData::getIndexedOffset to use ArrayRef.
[oota-llvm.git] / lib / Analysis / Loads.cpp
index 1f554a3da26c155bf101a1bc8e994e2934149c90..18f3a3465b5d2d01cfa2bf887f8ec6dfde9fc9ac 100644 (file)
@@ -63,7 +63,7 @@ static Value *getUnderlyingObjectWithOffset(Value *V, const TargetData *TD,
         return V;
       SmallVector<Value*, 8> Indices(GEP->op_begin() + 1, GEP->op_end());
       ByteOffset += TD->getIndexedOffset(GEP->getPointerOperandType(),
-                                         &Indices[0], Indices.size());
+                                         Indices);
       V = GEP->getPointerOperand();
     } else if (Operator::getOpcode(V) == Instruction::BitCast) {
       V = cast<Operator>(V)->getOperand(0);