diff options
Diffstat (limited to 'lib/Transforms/Scalar/ScalarReplAggregates.cpp')
-rw-r--r-- | lib/Transforms/Scalar/ScalarReplAggregates.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/Transforms/Scalar/ScalarReplAggregates.cpp b/lib/Transforms/Scalar/ScalarReplAggregates.cpp index 057bc6f5c9..5bbb5aef03 100644 --- a/lib/Transforms/Scalar/ScalarReplAggregates.cpp +++ b/lib/Transforms/Scalar/ScalarReplAggregates.cpp @@ -834,7 +834,7 @@ const Type *SROA::CanConvertToScalar(Value *V, bool &IsNotTrivial) { } else if (GEP->getNumOperands() == 3 && isa<ConstantInt>(GEP->getOperand(1)) && isa<ConstantInt>(GEP->getOperand(2)) && - cast<Constant>(GEP->getOperand(1))->isNullValue()) { + cast<ConstantInt>(GEP->getOperand(1))->isZero()) { // We are stepping into an element, e.g. a structure or an array: // GEP Ptr, int 0, uint C const Type *AggTy = PTy->getElementType(); |