[PATCH] D91718: [LV] Legalize scalable VF hints

David Sherwood via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Dec 15 06:51:29 PST 2020


david-arm added inline comments.


================
Comment at: llvm/lib/Transforms/Vectorize/LoopVectorize.cpp:7442
+  if (!UserVF.isZero() &&
+      (UserVFIsLegal || (UserVF.isScalable() && MaxVF.isScalable()))) {
+    // FIXME: MaxVF is temporarily used inplace of UserVF for illegal scalable
----------------
david-arm wrote:
> Is this additional check necessary here? It looks like MaxVF came from computeMaXVF, which makes use of your clamping code above. If you revert this change do your tests still pass?
Ah I think I misunderstood what the clamping above is doing. It only clamps MaxVF, not UserVF. I wonder if it's worth emitting a remark for this case to let the user know something happened? It might look a bit odd if we downgrade their VF without telling them. I guess it depends upon how quick we get a fix for this.


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

https://reviews.llvm.org/D91718



More information about the llvm-commits mailing list