[llvm] [LoopInterchange] Improve profitability check for vectorization (PR #133672)
Ryotaro Kasuga via llvm-commits
llvm-commits at lists.llvm.org
Tue Jul 15 11:18:26 PDT 2025
================
@@ -103,3 +103,135 @@ for.i.inc:
exit:
ret void
}
+
+; Check that the below loops are exchanged to allow innermost loop
+; vectorization. We cannot vectorize the j-loop because it has a lexically
+; backward dependency, but the i-loop can be vectorized because all the
+; loop-carried dependencies are lexically forward.
----------------
kasuga-fj wrote:
I meant to continue with something like this (which I should have written): Therefore, interchanging the loops could help `LoopVectorize`.
(But that also means we don’t know whether the loop will actually be vectorized…)
https://github.com/llvm/llvm-project/pull/133672
More information about the llvm-commits
mailing list