[PATCH] D101836: [LoopVectorize] Enable strict reductions when allowReordering() returns false
Kerry McLaughlin via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed May 5 07:48:28 PDT 2021
kmclaughlin updated this revision to Diff 343044.
kmclaughlin marked 2 inline comments as done.
kmclaughlin added a comment.
Addressing review comments from @sdesmalen & @david-arm:
- Merged `canVectorizeFPMath` with `canVectorizeOrderedFPMath` in LoopVectorizationLegality
- Only check the IsOrdered flag of the RecurrenceDescriptor if hasExactFPMath() is true.
- Added a test with different types of reductions (integer add & FP add) that we should be able to vectorize with the -enable-strict-reductions flag
Also added an extra RUN line to both strict-fadd.ll & scalable-strict-fadd.ll to test the changes made to allowReordering (i.e. changing `EC.getKnownMinValue()` > 1 to `EC.isScalar()`).
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D101836/new/
https://reviews.llvm.org/D101836
Files:
llvm/include/llvm/Transforms/Vectorize/LoopVectorizationLegality.h
llvm/lib/Transforms/Vectorize/LoopVectorizationLegality.cpp
llvm/lib/Transforms/Vectorize/LoopVectorize.cpp
llvm/test/Transforms/LoopVectorize/AArch64/scalable-strict-fadd.ll
llvm/test/Transforms/LoopVectorize/AArch64/strict-fadd.ll
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D101836.343044.patch
Type: text/x-patch
Size: 51727 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20210505/b74fbe88/attachment.bin>
More information about the llvm-commits
mailing list