[Mlir-commits] [mlir] [mlir][vector] Update the folder for vector.{insert|extract} (PR #136579)

Fehr Mathieu llvmlistbot at llvm.org
Mon Apr 21 12:00:08 PDT 2025


math-fehr wrote:

Thanks for fixing my tests, I'll make sure to follow the testing guide next time!

About the canonicalization, my understanding is that this `-1` should be considered as an
OOB access, as only `-1` constants (as in `-1` attributes) are representing poison accesses (if I understand correctly). This change would mean that OOB accesses are not folded to poison,
unless the OOB access in `-1`, which feels weird to me.

I thought that the reason `-1` was used was that it is not possible to have an `#ub.poison` attribute in the constant index array in `vector.insert`. And that this was to fold the following:
```
%poison = ub.poison : index
%0 = vector.insert %value_to_store, %dest[%poison] : vector<5xf32> into vector<4x5xf32>
```

What do you think? Or please tell me if I'm misunderstanding something

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


More information about the Mlir-commits mailing list