4 Commits

Author SHA1 Message Date
Frank Schlimbach
9269aaecff
[mlir][mesh] fixes for 0d tensors (#132948)
In some cases 0d tensors have no sharding. This PR provides a few minor
fixes to account for such cases.
2025-03-26 18:13:41 +01:00
Frank Schlimbach
6e57326c61
[mlir][mesh, mpi] More on MeshToMPI (#129048)
- do not create MPI operations if no halo exchange is needed
- allow returning sharding information through `!mesh.sharding`
  (gets converted into a tuple of tensors)
- lowering `mesh.shard_shape` including fixes to the operation itself
- global symbol `static_mpi_rank` replaced by an DLTI attribute
  (now aligned with MPIToLLVM)
- smaller fixes and some minor cleanup

---------

Co-authored-by: Christian Ulmann <christianulmann@gmail.com>
2025-03-06 10:47:06 +01:00
Frank Schlimbach
0fd50ec9a3
[MLIR][mesh] Mesh fixes (#124724)
A collection of fixes to the mesh dialect
- allow constants in sharding propagation/spmdization
- fixes to tensor replication (e.g. 0d tensors)
- improved canonicalization
- sharding propagation incorrectly generated too many ShardOps
New operation `mesh.GetShardOp` enables exchanging sharding information
(like on function boundaries)
2025-02-12 12:44:48 +01:00
Frank Schlimbach
681ae09722
[MLIR][mesh] moving shardinginterfaceimpl for tensor to tensor extension lib (#104913)
Follow-up to #102598 : as discussed, move tensor sharding implementation
into separate tensor extension lib.

@sogartar @yaochengji, could you take a look at this PR?
2024-08-21 11:59:44 +01:00