[SVE] Bail from VectorUtils heuristics for scalable vectors
authorChristopher Tetreault <ctetreau@quicinc.com>
Thu, 10 Sep 2020 18:29:16 +0000 (11:29 -0700)
committerChristopher Tetreault <ctetreau@quicinc.com>
Thu, 10 Sep 2020 19:29:37 +0000 (12:29 -0700)
commit7ddfd9b3ebfd3f3db7c6c2e8c72308ff3a3426f2
tree9c434957357b344f76bcc821725190cd1e836132
parent783e28a50839e045b72ec11946295fba104642fc
[SVE] Bail from VectorUtils heuristics for scalable vectors

Bail from maskIsAllZeroOrUndef and maskIsAllOneOrUndef prior to iterating over the number of
elements for scalable vectors.

Assert that the mask type is not scalable in possiblyDemandedEltsInMask .

Assert that the types are correct in all three functions.

Reviewed By: efriedma

Differential Revision: https://reviews.llvm.org/D87424
llvm/include/llvm/Analysis/VectorUtils.h
llvm/lib/Analysis/VectorUtils.cpp
llvm/lib/Transforms/InstCombine/InstCombineCalls.cpp
llvm/test/Transforms/InstCombine/AArch64/VectorUtils_heuristics.ll [new file with mode: 0644]