-
Notifications
You must be signed in to change notification settings - Fork 53
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
Adding support for scheduling the epilogue computation when smem_epilogue parameter is true #3581
Open
protonu
wants to merge
9
commits into
main
Choose a base branch
from
pbasu_mma_epilogue_hopper_smem_epilogue
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Conversation
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
rdspring1
reviewed
Dec 12, 2024
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Here is my transformation helper. It can be used in scheduleMmaResult
. Just trying to avoid some merge conflicts.
void HopperMultipleMatmulScheduler::transformLikeMmaOutput(
TensorView* tv,
bool is_mma_result) {
// TODO Add constraints
auto apply_k_dim_offset = [is_mma_result](int64_t idx) constexpr {
return (is_mma_result) ? idx - 1 : idx;
};
// Original: [..., Mo, No, Mi, Ni]
tv->split(apply_k_dim_offset(-2), getM(params_->mma_macro));
tv->split(apply_k_dim_offset(-1), getN(params_->mma_macro));
// After Split: [..., Mo, No, Mio, Mii, Nio, Nii]
tv->reorder({{apply_k_dim_offset(-3), apply_k_dim_offset(-2)}});
// After Reorder: [..., Mo, No, Mio, Nio, Mii, Nii]
tv->merge(apply_k_dim_offset(-4));
// After Merge: [..., Mo, No, Mio * Nio, Mii, Nii]
tv->axis(apply_k_dim_offset(-3))->parallelize(ParallelType::TIDy);
// After Parallelize: [..., Mo, No, Mio * Nio (TIDy), Mii, Nii]
}
protonu
force-pushed
the
pbasu_mma_epilogue_hopper_no_smem_epilogue
branch
from
December 13, 2024 18:41
94f39a1
to
be5f18b
Compare
protonu
force-pushed
the
pbasu_mma_epilogue_hopper_smem_epilogue
branch
from
December 13, 2024 20:59
b9df449
to
aa86b8b
Compare
!build |
protonu
force-pushed
the
pbasu_mma_epilogue_hopper_no_smem_epilogue
branch
from
December 14, 2024 01:42
895df0f
to
09cb407
Compare
protonu
force-pushed
the
pbasu_mma_epilogue_hopper_smem_epilogue
branch
from
December 14, 2024 03:54
aa86b8b
to
c0cfa4e
Compare
protonu
force-pushed
the
pbasu_mma_epilogue_hopper_smem_epilogue
branch
from
December 14, 2024 03:55
c0cfa4e
to
af126a1
Compare
Base automatically changed from
pbasu_mma_epilogue_hopper_no_smem_epilogue
to
main
December 14, 2024 14:46
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Refactoring some code and adding some support for smem_epilogue