[Mlir-commits] [mlir] [mlir][VectorToLLVM] emit `inbounds|nuw` GEP flags when lowering `vector.load/store` (PR #202118)
Krzysztof Drewniak
llvmlistbot at llvm.org
Fri Jun 12 09:15:43 PDT 2026
krzysz00 wrote:
So, as far as I'm concerned, we should add `inbounds` and `nneg` flags to `vector.load`, and not emit inbounds or nusw by default, as, from where I'm standing, `vector.load %mem[-1] : vector<4xf32>, memref<8xf32, #spirv.relevant_buffer_kind>` is a completely valid operation in the presence of extensions like SPIR-V robust buffer access (it'll return something like `<0, mem[0], mem[1], mem[2]>`. Similarly, `vector.load %mem[8] : vector<4xf32>, memref<8xf32, #amdgpu.address_space<raw_fat_buffer_pointer>>` is a valid and fairly contrived way to get your hands on `<0, 0, 0, 0>` and we shouldn't break that sort of thing.
https://github.com/llvm/llvm-project/pull/202118
More information about the Mlir-commits
mailing list