-
Notifications
You must be signed in to change notification settings - Fork 24.2k
[not for land] small compile-on-one-rank example #153743
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
Open
bdhirsh
wants to merge
1
commit into
gh/bdhirsh/663/base
Choose a base branch
from
gh/bdhirsh/663/head
base: gh/bdhirsh/663/base
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.
Open
Conversation
This file contains hidden or 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
[ghstack-poisoned]
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
ciflow/inductor
fx
module: dynamo
module: inductor
oncall: distributed
Add this issue/PR to distributed oncall triage queue
release notes: distributed (c10d)
release notes category
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.
This is just for stashing changes (it is full of hacks and is missing features). See
precompile_on_one_symbolic_rank_example.py
for the example code, which splits the job into two steps (pre-compile on a single rank, run distributed job with that shared artifact)Linking the generated output code in a bit, where the main feature you can see is that:
(1) rank is an input to the compiled artifact
(2) the triton kernels hardcode
torch.distributed.get_rank()
instead of the rank they were compiled with (to be fair this is not actually what we want, since it implies that each rank needs to compile the triton kernels separately. but at the very least the same compiled artifact python file can be shared by every rank)Stack from ghstack (oldest at bottom):
cc @H-Huang @awgu @wanchaol @fegin @fduwjj @wz337 @wconstab @d4l3k @ezyang @SherlockNoMad @EikanWang @jgong5 @wenzhe-nrv @voznesenskym @penguinwu @Guobing-Chen @XiaobingSuper @zhuhaozhe @blzheng @jiayisunx @ipiszy @chenyang78 @kadeng @muchulee8 @amjames @chauhang @aakhundov