[llvm] [LV]Initial support for safe distance in predicated DataWithEVL vectorization mode. (PR #102897)

Florian Hahn via llvm-commits llvm-commits at lists.llvm.org
Mon Aug 19 00:55:15 PDT 2024


================
@@ -471,6 +471,11 @@ Value *VPInstruction::generatePerPart(VPTransformState &State, unsigned Part) {
       assert(State.VF.isScalable() && "Expected scalable vector factor.");
       Value *VFArg = State.Builder.getInt32(State.VF.getKnownMinValue());
 
+      if (getNumOperands() == 3) {
----------------
fhahn wrote:

```suggestion
      // If a maximum safe number of elements has been provided, limit AVL by it.
      if (getNumOperands() == 3) {
```

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


More information about the llvm-commits mailing list