Skip to content
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

Fix for MPS regression in #122016 and #123178 #123385

Merged
merged 1 commit into from Apr 5, 2024

Conversation

pytorchbot
Copy link
Collaborator

Fixes #122016 and #123178. This regression is related to an OS side change that requires a slight adjustment from us on PyTorch side to restore the previous behavior. Additionally we cleared out pre-MacOS13 related workarounds.

Before the fix on MacOS 14.4:

python -c "import torch;x=torch.zeros(3, device='mps');x[1] = 1; x[2] = 3; print(x)"
tensor([0., 3., 3.], device='mps:0')

After the fix:

python -c "import torch;x=torch.zeros(3, device='mps');x[1] = 1; x[2] = 3; print(x)"
tensor([0., 1., 3.], device='mps:0')

This also fixes complex number initialization and as such makes nn.functional.rms_norm pass on MacOS-14+

Copy link

pytorch-bot bot commented Apr 4, 2024

🔗 Helpful Links

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

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

❌ 24 New Failures, 2 Unrelated Failures

As of commit 7426754 with merge base 86a2d67 (image):

NEW FAILURES - The following jobs have failed:

FLAKY - The following jobs failed but were likely due to flakiness present on trunk:

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

@pytorch-bot pytorch-bot bot added ciflow/mps Run MPS tests (subset of trunk) release notes: mps Release notes category labels Apr 4, 2024
@malfet
Copy link
Contributor

malfet commented Apr 5, 2024

@pytorchbot rebase -b release/2.3

@pytorchmergebot
Copy link
Collaborator

@pytorchbot started a rebase job onto refs/remotes/origin/release/2.3. Check the current status here

Fixes #122016 and #123178. This regression is related to an OS side change that requires a slight adjustment from us on PyTorch side to restore the previous behavior. Additionally we cleared out pre-MacOS13 related workarounds.

Before the fix on MacOS 14.4:

```
python -c "import torch;x=torch.zeros(3, device='mps');x[1] = 1; x[2] = 3; print(x)"
tensor([0., 3., 3.], device='mps:0')
```

After the fix:
```
python -c "import torch;x=torch.zeros(3, device='mps');x[1] = 1; x[2] = 3; print(x)"
tensor([0., 1., 3.], device='mps:0')
```

This also fixes complex number initialization and as such makes `nn.functional.rms_norm` pass on MacOS-14+

Co-authored-by: Nikita Shulga <2453524+malfet@users.noreply.github.com>
Pull Request resolved: #123234
Approved by: https://github.com/malfet, https://github.com/kulinseth

(cherry picked from commit 05289a2)
@pytorchmergebot
Copy link
Collaborator

Successfully rebased cherry-pick-123234-by-pytorch_bot_bot_ onto refs/remotes/origin/release/2.3, please pull locally before adding more changes (for example, via git checkout cherry-pick-123234-by-pytorch_bot_bot_ && git pull --rebase)

@pytorchmergebot pytorchmergebot force-pushed the cherry-pick-123234-by-pytorch_bot_bot_ branch from 20b0c97 to 7426754 Compare April 5, 2024 22:22
@atalman atalman merged commit fb38ab7 into release/2.3 Apr 5, 2024
25 of 47 checks passed
@atalman atalman deleted the cherry-pick-123234-by-pytorch_bot_bot_ branch April 5, 2024 22:46
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) open source release notes: mps Release notes category
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants