KEMBAR78
[MPS] Fix index_add for complex + int64 by malfet · Pull Request #160926 · pytorch/pytorch · GitHub
Skip to content

Conversation

@malfet
Copy link
Contributor

@malfet malfet commented Aug 19, 2025

Stack from ghstack (oldest at bottom):

By re-using deterministic algorithm from

if (globalContext().deterministicAlgorithms()){
torch::List<std::optional<Tensor>> indices;
indices.reserve(dim + 1);
for (const auto i: c10::irange(dim)) {
indices.emplace_back();
}
indices.emplace_back(index.to(at::kLong));
result.index_put_(indices, source * alpha, true);

Fixes #160845

@malfet malfet requested a review from kulinseth as a code owner August 19, 2025 00:19
@pytorch-bot
Copy link

pytorch-bot bot commented Aug 19, 2025

🔗 Helpful Links

🧪 See artifacts and rendered test results at hud.pytorch.org/pr/160926

Note: Links to docs will display an error until the docs builds have been completed.

⏳ No Failures, 1 Pending

As of commit 87a151a with merge base 114813c (image):
💚 Looks good so far! There are no failures yet. 💚

This comment was automatically generated by Dr. CI and updates every 15 minutes.

malfet added a commit that referenced this pull request Aug 19, 2025
@pytorch-bot pytorch-bot bot added ciflow/mps Run MPS tests (subset of trunk) release notes: mps Release notes category labels Aug 19, 2025
@malfet malfet added topic: bug fixes topic category ciflow/trunk Trigger trunk jobs on your pull request labels Aug 19, 2025
@malfet
Copy link
Contributor Author

malfet commented Aug 19, 2025

@pytorchbot merge -f "Everything is green"

@pytorchmergebot
Copy link
Collaborator

Merge started

Your change will be merged immediately since you used the force (-f) flag, bypassing any CI checks (ETA: 1-5 minutes). Please use -f as last resort and instead consider -i/--ignore-current to continue the merge ignoring current failures. This will allow currently pending tests to finish and report signal before the merge.

Learn more about merging in the wiki.

Questions? Feedback? Please reach out to the PyTorch DevX Team

Advanced Debugging
Check the merge workflow status
here

pytorchmergebot pushed a commit that referenced this pull request Aug 21, 2025
Which enables them on MPS device
- xfail all `test_index_reduce` on MPS, as op is not implemented
- xfail all `test_index_copy` on MPS due to the silent correctness problems, see #160993
- Fixed hard crash in `index_fill` and replaced `skipIfMPS` with `expectedFailueMPS`
- Created issue for the lack of deterministic algorithms for MPS backend
Pull Request resolved: #160994
Approved by: https://github.com/manuelcandales
ghstack dependencies: #160850, #160889, #160926
markc-614 pushed a commit to markc-614/pytorch that referenced this pull request Sep 17, 2025
Which enables them on MPS device
- xfail all `test_index_reduce` on MPS, as op is not implemented
- xfail all `test_index_copy` on MPS due to the silent correctness problems, see pytorch#160993
- Fixed hard crash in `index_fill` and replaced `skipIfMPS` with `expectedFailueMPS`
- Created issue for the lack of deterministic algorithms for MPS backend
Pull Request resolved: pytorch#160994
Approved by: https://github.com/manuelcandales
ghstack dependencies: pytorch#160850, pytorch#160889, pytorch#160926
@github-actions github-actions bot deleted the gh/malfet/494/head branch September 19, 2025 02:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ciflow/mps Run MPS tests (subset of trunk) ciflow/trunk Trigger trunk jobs on your pull request Merged release notes: mps Release notes category topic: bug fixes topic category

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants