[PATCH] D98054: [LoopVectorize][SVE] Fix crash when vectorising FP negation

David Sherwood via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Mar 12 08:29:19 PST 2021


david-arm added a comment.

Hi @sdesmalen, thanks for pointing this out! It looks like for the cases you listed above we actually have:

1. VF is scalar, in which case N=1. The code in getInstructionCost is misleading since `VectorTy` is actually the element type in this case!
2. VF is a vector. If this is an instruction to be scalarised then it will live in InstsInScalarize and the higher level getInstructionCost will deal with this separately. It seems that isScalarAfterVectorization returns true if the instruction is a member of the Scalars variable. From what I can tell the members of Scalars fall into two main categories: GEPs/bitcasts with scalar uses, induction variable updates with scalar uses. In these cases the instruction will remain as a single scalar instruction.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D98054/new/

https://reviews.llvm.org/D98054



More information about the llvm-commits mailing list