[llvm] [LV][EVL] Generate negative strided load/store for reversed load/store (PR #123608)

Mel Chen via llvm-commits llvm-commits at lists.llvm.org
Tue Jan 21 08:51:05 PST 2025


================
@@ -7433,6 +7433,13 @@ static bool planContainsAdditionalSimplifications(VPlan &Plan,
       // comparing against the legacy cost isn't desirable.
       if (isa<VPPartialReductionRecipe>(&R))
         return true;
+
+      // The VPlan-based cost model may calculate the cost of strided load/store
+      // which can't be modeled in the legacy cost model.
+      if (isa<VPWidenLoadEVLRecipe>(&R) || isa<VPWidenStoreEVLRecipe>(&R))
----------------
Mel-Chen wrote:

```suggestion
      if (isa<VPWidenLoadEVLRecipe, VPWidenStoreEVLRecipe>(&R))
```

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


More information about the llvm-commits mailing list