[PATCH] D128272: [LoopVectorize] Change PredicatedBBsAfterVectorization to be per VF

Sander de Smalen via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Jul 4 09:26:14 PDT 2022


sdesmalen added a comment.
Herald added a subscriber: shiva0217.

Thanks for the changes @david-arm. I just have a few more comments on the test.



================
Comment at: llvm/test/Transforms/LoopVectorize/AArch64/sve-tail-folding-cost.ll:13-15
+; CHECK-NOT: LV: Vector loop of width vscale x 2 costs: Invalid
+; CHECK-NOT: LV: Vector loop of width vscale x 4 costs: Invalid
+; CHECK: LV: Selecting VF: vscale x 4
----------------
If it selects VF=vscale x 4 then it seems redundant to check there is no invalid cost for that chosen VF.

If you want to check that it uses a scalable VF, you don't need the debug-output to tell you it chose that. You could remove the `REQUIRES: asserts`, the `-debug` option from the RUN line and instead check for `<vscale x 4 x i32>` in the resulting IR. What do you think?

Just a note that this test may become redundant in the future if SVE is used for fixed-width vectors and it can lower fixed-width masked load/store operations to use SVE. Maybe you can add a note here that this assumption is important for the test and may change in the future?


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D128272/new/

https://reviews.llvm.org/D128272



More information about the llvm-commits mailing list