[all-commits] [llvm/llvm-project] ef48e9: LoopVectorize/iv-select-cmp: add test for decreasi...
Ramkumar Ramachandra via All-commits
all-commits at lists.llvm.org
Mon Sep 25 05:20:54 PDT 2023
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: ef48e90489dc219568f46a9c36da80adfb759ad7
https://github.com/llvm/llvm-project/commit/ef48e90489dc219568f46a9c36da80adfb759ad7
Author: Ramkumar Ramachandra <Ramkumar.Ramachandra at imgtec.com>
Date: 2023-09-25 (Mon, 25 Sep 2023)
Changed paths:
M llvm/test/Transforms/LoopVectorize/iv-select-cmp.ll
Log Message:
-----------
LoopVectorize/iv-select-cmp: add test for decreasing IV out-of-bound
The most straightforward extension to D150851 would involve handling the
decreasing IV case, for which tests have been added in 110ec1863a
(LoopVectorize/iv-select-cmp: add test for decreasing IV, const start).
However, the commit missed a testcase for the out-of-bound sentinel
value LONG_MAX, which should not be vectorized. Fix this by adding a
test corresponding to the following program:
long test(long *a) {
long rdx = 331;
for (long i = LONG_MAX; i >= 0; i--) {
if (a[i] > 3)
rdx = i;
}
return rdx;
}
Differential Revision: https://reviews.llvm.org/D157969
More information about the All-commits
mailing list