-
Notifications
You must be signed in to change notification settings - Fork 24.3k
[Inductor] Pick ISA for inductor based on ATEN_CPU_CAPABILITY #123514
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
Conversation
🔗 Helpful Links🧪 See artifacts and rendered test results at hud.pytorch.org/pr/123514
Note: Links to docs will display an error until the docs builds have been completed. ✅ You can merge normally! (1 Unrelated Failure)As of commit 38ec5c4 with merge base 67883e7 ( FLAKY - The following job failed but was likely due to flakiness present on trunk:
This comment was automatically generated by Dr. CI and updates every 15 minutes. |
torch/_inductor/codecache.py
Outdated
and not isinstance(_valid_vec_isa_list[0], VecNEON) | ||
and not isinstance(_valid_vec_isa_list[0], VecZVECTOR) |
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.
compute_cpu_capability
also handles vsx and zvector. We should also consider them here?
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.
Taking VecNEON and VecZVECTOR into account.
static CPUCapability capability = compute_cpu_capability(); | ||
CPUCapability capability = compute_cpu_capability(); |
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.
Why removing static
here?
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.
Changed it back
torch/_inductor/codecache.py
Outdated
# If the simdlen is None, it indicates determin the vectorization length automatically | ||
if config.cpp.simdlen is None: | ||
assert _valid_vec_isa_list |
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.
perhaps we don't need this check any longer.
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.
Removed the check
Merge startedYour change will be merged once all checks pass (ETA 0-4 Hours). Learn more about merging in the wiki. Questions? Feedback? Please reach out to the PyTorch DevX Team |
@pytorchbot revert -m 'Sorry for reverting your change but its test_cpu_repro test is failing in trunk https://hud.pytorch.org/pytorch/pytorch/commit/6931c1644afdba53e63ce5671455e4e1b7265dd9' -c nosignal I think a rebase is needed |
@pytorchbot successfully started a revert job. Check the current status here. |
@CaoE your PR has been successfully reverted. |
…#123514)" This reverts commit 6931c16. Reverted #123514 on behalf of https://github.com/huydhn due to Sorry for reverting your change but its test_cpu_repro test is failing in trunk https://hud.pytorch.org/pytorch/pytorch/commit/6931c1644afdba53e63ce5671455e4e1b7265dd9 ([comment](#123514 (comment)))
…pytorch#123514)" This reverts commit 6931c16. Reverted pytorch#123514 on behalf of https://github.com/huydhn due to Sorry for reverting your change but its test_cpu_repro test is failing in trunk https://hud.pytorch.org/pytorch/pytorch/commit/6931c1644afdba53e63ce5671455e4e1b7265dd9 ([comment](pytorch#123514 (comment)))
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.
Please commit the suggested changes from pytorch's linter.
@huydhn The PR is rebased. Could you please help import this this PR to see if it will break internal checks ? |
Umm, unfortunately, I couldn't import this PR because it uses ghstack. Only the stack owner can do so (folks from Meta do that themselves). There is no work around that I know atm, so I think let's just merge this and let our oncall check it later then. |
@pytorchbot merge |
Merge startedYour change will be merged once all checks pass (ETA 0-4 Hours). Learn more about merging in the wiki. Questions? Feedback? Please reach out to the PyTorch DevX Team |
Stack from ghstack (oldest at bottom):
It is part of #123224. Pick ISA based on the environment ATEN_CPU_CAPABILITY to control CPU vec ISA level for Inductor like eager.
cc @ezyang @chauhang @penguinwu @voznesenskym @EikanWang @jgong5 @Guobing-Chen @XiaobingSuper @zhuhaozhe @blzheng @wenzhe-nrv @jiayisunx @ipiszy @yf225 @chenyang78 @kadeng @muchulee8 @ColinPeppler @amjames @desertfire @rec @msaroufim @bdhirsh @anijain2305 @peterbell10 @aakhundov