[PATCH] D24271: [LV] Don't mark pointers used by scalarized memory accesses uniform

Michael Kuperstein via llvm-commits llvm-commits at lists.llvm.org
Tue Sep 6 22:53:56 PDT 2016


mkuper added a comment.

Thanks, Matt!


================
Comment at: lib/Transforms/Vectorize/LoopVectorize.cpp:5290
@@ +5289,3 @@
+  if (auto *Ptr = getPointerOperand(I))
+    return isConsecutivePtr(Ptr);
+  return false;
----------------
I think this will also return true for "reverse consecutive".
Is that true? If so, is it intentional?

================
Comment at: lib/Transforms/Vectorize/LoopVectorize.cpp:5309
@@ +5308,3 @@
+  // scalarized.
+  if (SI && blockNeedsPredication(SI->getParent()) && !isMaskRequired(SI))
+    return true;
----------------
Any chance this and vectorizeMemoryInstruction can share code?
Having this duplicated scares me a bit.


https://reviews.llvm.org/D24271





More information about the llvm-commits mailing list