-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[shardy] Fix a bug for non-minor-most factors in `BasicFactorPropagat…
…ion::compatiblePrefixNoConflictsWithinFactor`. When the following conditions hold 1. factor is open 2. factor has NO existing overflow axes 3. factor is NOT minor-most 4. The axis to be considered is not contained in the existing sharding axes. Before this cl, we make decisions based on `factorSize % shardedSize == 0`. However, it is possible that we can append a sub-axis with size of `gcd(factorSize / shardedSize, axisSize)`. For the following reshape example ``` func.func @reshape_merge_dim_major_factor_overflows(%arg0: tensor<4x4xf32> {sdy.sharding = #sdy.sharding<@mesh_a_4_b_2_c_2, [{"b", "a"}, {}]>}) -> tensor<16xf32> { %0 = stablehlo.reshape %arg0 : (tensor<4x4xf32>) -> tensor<16xf32> return %0 : tensor<16xf32> } Result sharding * before this cl: [<@mesh_a_4_b_2_c_2, [{"b", ?}]>] * with this cl: [<@mesh_a_4_b_2_c_2, [{"b", "a":(1)2, ?}]>] ``` PiperOrigin-RevId: 682091772
- Loading branch information
1 parent
c464210
commit f669e68
Showing
42 changed files
with
2,472 additions
and
4,221 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.