[Mlir-commits] [mlir] [mlir][GPU] Add builders to allow passing in integer `upper_bound`s (PR #114252)

Krzysztof Drewniak llvmlistbot at llvm.org
Wed Oct 30 10:55:06 PDT 2024


================
@@ -74,7 +74,20 @@ class GPU_IndexOp<string mnemonic, list<Trait> traits = []> :
     }]>,
     OpBuilder<(ins "::mlir::Type":$resultType, "::mlir::gpu::Dimension":$dimension), [{
       build($_builder, $_state, resultType, dimension, /*upperBound=*/nullptr);
+    }]>,
+    OpBuilder<(ins "::mlir::gpu::Dimension":$dimension, "std::optional<int64_t>":$upperBound), [{
----------------
krzysz00 wrote:

So that you can explicitly pass in `std::nullopt` to leave the bound unset

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


More information about the Mlir-commits mailing list