[Mlir-commits] [mlir] [mlir][mesh] Add collective communication operations (PR #71960)

Boian Petkantchin llvmlistbot at llvm.org
Mon Nov 13 07:49:32 PST 2023


================
@@ -129,6 +205,347 @@ MeshShardingAttr::verify(function_ref<InFlightDiagnostic()> emitError,
   return success();
 }
 
+//===----------------------------------------------------------------------===//
+// collective communication ops
+//===----------------------------------------------------------------------===//
+
+namespace {
+
+std::optional<DenseI16ArrayAttr>
+canonicalizeAxesSetAttribute(DenseI16ArrayAttr attr) {
----------------
sogartar wrote:

I was thinking to change its meaning. In the Mesh.md doc it is stated that the order of devices is the same as the order of  their multi-index in the mesh. This would make it a set.
We can change the meaning where the order of devices could be induced by the order in `mesh_axes`. For example if `mesh_axes = [2, 1]` then device `(i, j, k)` would precede device `(i, l, m)` if `k > m`. This would influence operations like all-gather where order device order is important.

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


More information about the Mlir-commits mailing list