[all-commits] [llvm/llvm-project] 3c0363: [SVE][LoopVectorize] Add support for scalable vect...
CarolineConcatto via All-commits
all-commits at lists.llvm.org
Tue Mar 16 02:19:21 PDT 2021
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 3c03635d530066028aa3e041bc9e68743281e56b
https://github.com/llvm/llvm-project/commit/3c03635d530066028aa3e041bc9e68743281e56b
Author: Caroline Concatto <caroline.concatto at arm.com>
Date: 2021-03-16 (Tue, 16 Mar 2021)
Changed paths:
M llvm/include/llvm/IR/IRBuilder.h
M llvm/lib/IR/IRBuilder.cpp
M llvm/lib/Transforms/Vectorize/LoopVectorize.cpp
A llvm/test/Transforms/LoopVectorize/AArch64/sve-vector-reverse-mask4.ll
A llvm/test/Transforms/LoopVectorize/AArch64/sve-vector-reverse.ll
A llvm/test/Transforms/LoopVectorize/AArch64/vector-reverse-mask4.ll
A llvm/test/Transforms/LoopVectorize/AArch64/vector-reverse.ll
Log Message:
-----------
[SVE][LoopVectorize] Add support for scalable vectorization of loops with vector reverse
This patch adds support for reverse loop vectorization.
It is possible to vectorize the following loop:
```
for (int i = n-1; i >= 0; --i)
a[i] = b[i] + 1.0;
```
with fixed or scalable vector.
The loop-vectorizer will use 'reverse' on the loads/stores to make
sure the lanes themselves are also handled in the right order.
This patch adds support for scalable vector on IRBuilder interface to
create a reverse vector. The IR function
CreateVectorReverse lowers to experimental.vector.reverse for scalable vector
and keedp the original behavior for fixed vector using shuffle reverse.
Differential Revision: https://reviews.llvm.org/D95363
More information about the All-commits
mailing list