-
Notifications
You must be signed in to change notification settings - Fork 26.3k
[MPS] Add sort and argSort Op. #94697
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/94697
Note: Links to docs will display an error until the docs builds have been completed. ✅ No FailuresAs of commit da37aad: This comment was automatically generated by Dr. CI and updates every 15 minutes. |
DenisVieriu97
left a 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.
Looks good
|
@pytorchbot merge -f "MPS tests are green." |
Merge startedYour change will be merged immediately since you used the force (-f) flag, bypassing any CI checks (ETA: 1-5 minutes). Learn more about merging in the wiki. Questions? Feedback? Please reach out to the PyTorch DevX Team |
| descending:(BOOL)descending | ||
| name:@"sort_out"]; | ||
| sortedTensor = castFromIHFTypes(mpsGraph, sortedTensor, values); | ||
| MPSGraphTensor* argSortedTensor = [mpsGraph argSortWithTensor:castInputTensor |
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.
Is it correct understanding that MPSGraph internally will fuse these two together? I noticed that in [mpsGraph dump], the mps.sort IR emit two outputs (values, indices) while these two methods (sortWithTensor / argSortWithTensor) only extract one from that mps.sort inst. I imagine internally these two duplicate mps.sort will get de-duped through CSE?
Fixes #ISSUE_NUMBER