llvm-project
20c52e42 - Reapply "[RISCV][LoopVectorize] Use DataWithEVL as the preferred tail folding style (#148686)"

Commit
69 days ago
Reapply "[RISCV][LoopVectorize] Use DataWithEVL as the preferred tail folding style (#148686)" This reverts commit 25e97fc420f8ecc43fbabadfe9767b4163e6ee36. The original commit was reverted due to a crash in llvm-test-suite. The crash stemmed from a multiply reduction, which isn't supported for scalable VFs on RISC-V. But for EVL tail folding we only support scalable VFs, so when -force-tail-folding-style=data-with-evl is specified we check to see if there's a scalable VF, and fall back to data-without-lane-mask if there isn't. This is done in setTailFoldingStyles, but previously we were only checking if the forced tail folding style was legal, not the style returned by TTI. This version fixes this by checking the actual computed tail folding style and not just the forced one, and adds a test for the crash in llvm/test/Transforms/LoopVectorize/RISCV/low-trip-count.ll
Author
Committer
Parents
Loading