Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Multiple matmul fusion example #2458

Closed
wants to merge 162 commits into from
Closed

Multiple matmul fusion example #2458

wants to merge 162 commits into from

Conversation

jacobhinkle
Copy link
Collaborator

@jacobhinkle jacobhinkle commented Jun 26, 2024

Stacked on #2994

This adds a test matching the Llama FFN (forward), scheduling it all into one kernel.

@jacobhinkle jacobhinkle marked this pull request as ready for review September 23, 2024 15:59
@jacobhinkle jacobhinkle marked this pull request as draft September 23, 2024 15:59
@jacobhinkle jacobhinkle changed the base branch from main to multi_matmul_schedule_prologue September 23, 2024 15:59
jacobhinkle and others added 6 commits September 23, 2024 12:02
This is the latest in a series of PRs. It schedules `mma_result`.

Stacked on #2992.
This PR completes the scheduler by scheduling the epilogue and split-K
sum tensor, and enabling circular buffering.

Stacked on #2993
@jacobhinkle jacobhinkle changed the title [WIP] Multiple matmul fusion example Multiple matmul fusion example Sep 23, 2024
@jacobhinkle jacobhinkle changed the base branch from multi_matmul_schedule_prologue to multi_matmul_schedule_epilogue September 23, 2024 16:55
@jacobhinkle
Copy link
Collaborator Author

!build --matmul-bench

jacobhinkle added a commit that referenced this pull request Sep 24, 2024
This is the next PR in a series leading up to #2458. The previous PR
2913 scheduled the smem store and added the test framework. This PR
schedules the smem load and the prologue, i.e. everything up to the mma
instruction.

The next PRs in the series will do the following:
- Schedule the mma op result
- Schedule the epilogue including the split-K tensor
- Add test with horizontal fusion of matmuls (#2458)
- Switch to multiple matmul scheduler, i.e. remove old scheduleMatmul()
- Update matmul heuristic to account for horizontal fusion
- Update canSchedule checks to accept horizontally fused matmul segments
Base automatically changed from multi_matmul_schedule_epilogue to main September 27, 2024 17:47
@jacobhinkle jacobhinkle closed this Nov 4, 2024
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