Skip to content

[Codegen] Forward distribution inner-tile alignment hints in forall tiling - #24852

Draft
egebeysel wants to merge 1 commit into
users/egebeysel/scalable-dist-4-pack-distribution-hintsfrom
users/egebeysel/scalable-dist-5-distribution-tiling-tests
Draft

[Codegen] Forward distribution inner-tile alignment hints in forall tiling#24852
egebeysel wants to merge 1 commit into
users/egebeysel/scalable-dist-4-pack-distribution-hintsfrom
users/egebeysel/scalable-dist-5-distribution-tiling-tests

Conversation

@egebeysel

Copy link
Copy Markdown
Contributor

Threads the distribution-level inner-tile alignment hints (set on scalable
linalg.pack/linalg.unpack ops during lowering-strategy selection) into
TileAndDistributeToWorkgroupsUsingForall, via
makeInnerTileAlignmentFn(DistributionTiles) on both the tiling options and the
consumer-fusion step. With a Multiple hint the workgroup tiling folds a
scalable/dynamic inner tile to a clean tile ceildiv innerTile division instead
of leaving the pack/unpack untiled.

Adds lit coverage: two scalable pack/unpack cases (hint forwarded and preserved
through tiling) and a dynamic-inner-tile case where the hint is load-bearing —
the pack is only tiled into the forall because the hint asserts the multiple
relationship the driver cannot infer from the IR.

Co-Authored-By: Claude Opus 4.8 noreply@anthropic.com


Stack created with GitHub Stacks CLIGive Feedback 💬

@egebeysel
egebeysel force-pushed the users/egebeysel/scalable-dist-5-distribution-tiling-tests branch from 8e1c214 to a990a89 Compare August 25, 2026 16:39
@egebeysel
egebeysel force-pushed the users/egebeysel/scalable-dist-5-distribution-tiling-tests branch from a990a89 to c9e28a1 Compare August 25, 2026 16:58
@egebeysel
egebeysel force-pushed the users/egebeysel/scalable-dist-5-distribution-tiling-tests branch from c9e28a1 to 4c1273d Compare August 25, 2026 17:18
@egebeysel
egebeysel force-pushed the users/egebeysel/scalable-dist-5-distribution-tiling-tests branch from 4c1273d to 2639828 Compare August 25, 2026 17:23
…iling

Threads the distribution-level inner-tile alignment hints (set on scalable
`linalg.pack`/`linalg.unpack` ops during lowering-strategy selection) into
`TileAndDistributeToWorkgroupsUsingForall`, via
`makeInnerTileAlignmentFn(DistributionTiles)` on both the tiling options and the
consumer-fusion step. With a `Multiple` hint the workgroup tiling folds a
scalable/dynamic inner tile to a clean `tile ceildiv innerTile` division instead
of leaving the pack/unpack untiled.

Adds lit coverage: two scalable pack/unpack cases (hint forwarded and preserved
through tiling) and a dynamic-inner-tile case where the hint is load-bearing —
the pack is only tiled into the forall because the hint asserts the multiple
relationship the driver cannot infer from the IR.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Signed-off-by: Ege Beysel <beyselege@gmail.com>
@egebeysel
egebeysel force-pushed the users/egebeysel/scalable-dist-5-distribution-tiling-tests branch from 2639828 to 76575bc Compare August 26, 2026 15:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant