[PATCH] D101294: [LoopVectorize] Fix scalarisation crash in widenPHIInstruction for scalable vectors
Sander de Smalen via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon May 10 03:20:28 PDT 2021
sdesmalen added inline comments.
================
Comment at: llvm/lib/Transforms/Vectorize/LoopVectorize.cpp:3385
case InductionDescriptor::IK_IntInduction: {
+ assert(!isa<VectorType>(Index->getType()));
assert(Index->getType() == StartValue->getType() &&
----------------
Please add a message that this is not yet handled (although I guess it could be in the future?)
================
Comment at: llvm/lib/Transforms/Vectorize/LoopVectorize.cpp:3403
case InductionDescriptor::IK_FpInduction: {
+ assert(!isa<VectorType>(Index->getType()));
assert(Step->getType()->isFloatingPointTy() && "Expected FP Step value");
----------------
same here.
================
Comment at: llvm/lib/Transforms/Vectorize/LoopVectorize.cpp:4815
+ Value *UnitStepVec = nullptr, *PtrIndSplat = nullptr;
+ if (!IsUniform && VF.isScalable()) {
+ Type *VecIVTy = VectorType::get(PtrInd->getType(), VF);
----------------
nit: Can you move this out into a bool named `NeedsVectorIndex` ?
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D101294/new/
https://reviews.llvm.org/D101294
More information about the llvm-commits
mailing list