[PATCH] D90343: [POC][LoopVectorizer] Vectorize a simple loop with a scalable VF.
Sander de Smalen via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Nov 9 07:10:23 PST 2020
sdesmalen added a comment.
In D90343#2371495 <https://reviews.llvm.org/D90343#2371495>, @dmgreen wrote:
> This isn't as many changes as I was expecting. I had expected to need a lot of legality changes to make sure scalable vectorization was going to be correct too.
Sorry, I missed this comment earlier.
There are indeed not that many changes required for scalable vectors as you might expect to achieve some initial auto-vectorization. Some of the mechanisms are already able to cope with scalable vectors, such as reductions, for which we introduced the intrinsics a couple years ago because they can't be handled in a scalar reduction loop. For legalisation the most critical part that needs changing is the selection of the VF when there is a data-dependence. For scalable vectors, the maximum vector width must somehow take `vscale` into account, which must be sufficiently large/conservative for the vectorizer to guarantee that a loop with dependence distance of N bytes can be safely vectorized. In the absence of extra information provided by the user that tells about the min/max vector-width of a scalable vector, we can benefit from an architectural maximum vector length for AArch64 SVE/SVE2.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D90343/new/
https://reviews.llvm.org/D90343
More information about the llvm-commits
mailing list