[Mlir-commits] [mlir] [mlir][gpu] Add 'cluster_size' attribute to gpu.subgroup_reduce (PR #104851)

Kunwar Grover llvmlistbot at llvm.org
Tue Aug 20 04:54:33 PDT 2024


================
@@ -629,6 +637,10 @@ OpFoldResult gpu::SubgroupReduceOp::fold(FoldAdaptor /*adaptor*/) {
     return getResult();
   }
 
+  if (getClusterSize() == 1) {
+    return getValue();
+  }
----------------
Groverkss wrote:

nit: drop braces

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


More information about the Mlir-commits mailing list