[llvm] [LV][EVL]Support reversed loads/stores. (PR #88025)

Florian Hahn via llvm-commits llvm-commits at lists.llvm.org
Wed Apr 24 12:39:38 PDT 2024


================
@@ -9385,6 +9376,16 @@ void VPWidenLoadEVLRecipe::execute(VPTransformState &State) {
   Value *Mask = getMask()
                     ? State.get(getMask(), 0)
                     : Builder.CreateVectorSplat(State.VF, Builder.getTrue());
+  if (isReverse() && getMask()) {
+    VectorType *MaskTy = cast<VectorType>(Mask->getType());
+    Mask = Builder.CreateIntrinsic(
----------------
fhahn wrote:

Would be good to move the code to create the vp.reserves with an all-true mask to a static helper, to be used in various places.

https://github.com/llvm/llvm-project/pull/88025


More information about the llvm-commits mailing list