Skip to content

[Pallas] Ordered carry store for jagged row tiles#2719

Open
thcmbs wants to merge 1 commit into
thcmbs/stack/2from
thcmbs/stack/3
Open

[Pallas] Ordered carry store for jagged row tiles#2719
thcmbs wants to merge 1 commit into
thcmbs/stack/2from
thcmbs/stack/3

Conversation

@thcmbs

@thcmbs thcmbs commented Jun 8, 2026

Copy link
Copy Markdown
Collaborator

Stacked PRs:


We implement the carry in this PR. When a group's first or last block isn't aligned, its window overlaps the neighbour on one row. A grid-level scratch stitches it: fold the previous group's partial into the first block (out[:S] += carry), save this group's partial from the last block (carry = out[-S:]). Saving the folded value keeps it cumulative, so several tiny groups in one row compose. Relies on groups running in order, which the grid guarantees.

Does: jagged matmul correct on f32 and bf16 across the tested layouts (shared boundaries, tiny/odd groups, block bigger than a group, multiple column tiles), checked against a per-group reference. A plain map-axis store (out[st] = 2 * jagged[st]) uses the same path.

Gaps (I left TODOs to keep track of them and iterate with follow ups):

thcmbs added a commit that referenced this pull request Jun 8, 2026
stack-info: PR: #2719, branch: thcmbs/stack/3
@meta-cla meta-cla Bot added the CLA Signed This label is managed by the Meta Open Source bot. label Jun 8, 2026
thcmbs added a commit that referenced this pull request Jun 8, 2026
stack-info: PR: #2719, branch: thcmbs/stack/3
thcmbs added a commit to thcmbs/helion that referenced this pull request Jun 8, 2026
stack-info: PR: pytorch#2719, branch: thcmbs/stack/3
@thcmbs thcmbs force-pushed the thcmbs/stack/2 branch 2 times, most recently from 364969f to a054371 Compare June 8, 2026 18:26
thcmbs added a commit that referenced this pull request Jun 8, 2026
stack-info: PR: #2719, branch: thcmbs/stack/3
thcmbs added a commit to thcmbs/helion that referenced this pull request Jun 11, 2026
stack-info: PR: pytorch#2719, branch: thcmbs/stack/3
thcmbs added a commit that referenced this pull request Jun 11, 2026
stack-info: PR: #2719, branch: thcmbs/stack/3
thcmbs added a commit that referenced this pull request Jun 11, 2026
stack-info: PR: #2719, branch: thcmbs/stack/3
thcmbs added a commit that referenced this pull request Jun 11, 2026
stack-info: PR: #2719, branch: thcmbs/stack/3
thcmbs added a commit that referenced this pull request Jun 11, 2026
stack-info: PR: #2719, branch: thcmbs/stack/3
stack-info: PR: #2719, branch: thcmbs/stack/3
@thcmbs thcmbs marked this pull request as ready for review June 11, 2026 16:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CLA Signed This label is managed by the Meta Open Source bot.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant