[VPlan] Address post-commit suggestions for af635a554 (NFC).

This commit is contained in:
Florian Hahn 2023-08-08 12:59:33 +01:00
parent e8efe7f9d1
commit b6d994de0f
No known key found for this signature in database
GPG Key ID: 9E54DEA47A8F4434
2 changed files with 3 additions and 2 deletions

View File

@ -969,7 +969,7 @@ public:
bool hasNoSignedWrap() const {
assert(OpType == OperationType::OverflowingBinOp &&
"recipe doesn't have a NUW flag");
"recipe doesn't have a NSW flag");
return WrapFlags.HasNSW;
}

View File

@ -320,7 +320,8 @@ Value *VPInstruction::generateInstruction(VPTransformState &State,
// The canonical IV is incremented by the vectorization factor (num of SIMD
// elements) times the unroll part.
Value *Step = createStepForVF(Builder, IV->getType(), State.VF, Part);
return Builder.CreateAdd(IV, Step, Name, hasNoUnsignedWrap(), false);
return Builder.CreateAdd(IV, Step, Name, hasNoUnsignedWrap(),
hasNoSignedWrap());
}
case VPInstruction::BranchOnCond: {
if (Part != 0)