Repository navigation
Conversation
…PS coverage The mac2-m2pro fleet shift (pytorch/test-infra#8964) is deployed: macos-m2-26 now has 28 runners and macos-m2-27 (macOS 27) has 8. Undo the temporary pause from pytorch#201231: - trunk.yml: re-add the mps shard on macos-m2-26 - inductor-perf-test-nightly-macos.yml: restore the nightly schedule - mac-mps.yml: add test_mps on macos-m2-27 (macOS 15 / 26 / 27 coverage) - actionlint.yaml / pr-review runner list: add macos-m2-27
PR Status: in progressA maintainer requested changes. Please address their feedback before the PR returns to maintainer review. To become ready for review, the change must pass automated review and every maintainer comment must be addressed, either with a code change or a reply explaining why no change is needed. A fresh automated review checks that the feedback has been addressed. All CI must finish and Dr. CI must classify every failure as unrelated to your PR. Fix the failures it attributes to your PR (see status below in this comment). Workflows waiting for a maintainer to approve their run do not block this. To minimize iteration time, feel free to run the pr-review skill from the repo locally. If you address comments without pushing, comment 🟡 AUTOMATED REVIEW - Changes requested:
Findings (4): Reviewed commit: 🔗 Helpful Links🧪 See artifacts and rendered test results at hud.pytorch.org/pr/201517
Note: Links to docs will display an error until the docs builds have been completed. ✅ No FailuresAs of commit 43f9636 with merge base f21bd8f ( 🟡 GREEN LIGHT - OUTDATED (earlier commit) - PR requires human review:
reason: This comment was automatically generated by Dr. CI and updates every 15 minutes. |
|
oh wow, MPS Graph reintroduced a bug in 27.0 for matmuls 🫠 |
|
Works on 27.0.1 and 27.2 though, @malfet I think we should just stop gating the workaround on macOS for this case and do that workaround across all macOSes. |
MPSGraph matrixMultiplication with stride-0 inputs (only every 16th row computed, pytorch#180201) is fixed in macOS 26.4 but regressed in macOS 27.0.0; 27.0.1 and later are fine. mm only applied the contiguify workaround on macOS < 26.4, so on 27.0.0 test_mm_stride_zero failed (960/1024 elements wrong) on the new macos-m2-27 runners. Add a patch-level MacOSVersion::MACOS_27_0_1 and widen the gate to '< 26.4 || 27.0.0'. Behaviour is unchanged on every other macOS version, and only mm with non-complex stride-0 inputs takes the gather/clone path.
There was a problem hiding this comment.
Automated review of 43f9636: changes requested before human review.
The PR turns the macOS M2 trunk mps shard and the perf nightly back on, adds a test_mps job on macos-m2-27, and widens the mm stride-0 contiguify workaround (# 180201) to cover macOS 27.0.0. Recommendation: Request Changes. Two things block it: @ Isalia20's comment hasn't been answered, and the new macos-m2-27 runner label doesn't follow the runner naming standard.
🔴 2 blocking findings are attached to the code below.
⚪ 2 non-blocking findings
The gate's comment overstates what was tested. It says "26.4+ and 27.0.1+ are fine", but the PR description says only 27.0.1 and 27.2 were checked; 27.1 wasn't. If the gate stays, fix the comment to list only the versions that were actually verified.
pytorch/.github/workflows/trunk.yml
Line 259 in 43f9636
Heads-up (non-blocking): macos-m2-26 also breaks the runner naming standard. The re-added mps row has the same field problems as macos-m2-27. Other CI already uses the label (mac-mps.yml:36 and inductor-perf-test-nightly-macos.yml:54-59), so it doesn't block this PR.
Please address the findings and push; a new commit normally gets a fresh automated review.
This review is AI-generated and advisory. Each new automated review replaces the previous one.
| // the strided API so they go through the gather/clone path first. | ||
| // See https://github.com/pytorch/pytorch/issues/180201 | ||
| static const bool is_macOS_26_4_or_newer = is_macos_at_least(MacOSVersion::MACOS_26_4); | ||
| static const bool has_stride_zero_mm_bug = !is_macos_at_least(MacOSVersion::MACOS_26_4) || |
There was a problem hiding this comment.
🔴 Unaddressed maintainer comment (@ Isalia20). @ Isalia20 suggested dropping the macOS version gate entirely and applying the stride-0 workaround on every macOS version, since MPSGraph has now brought this bug back once. The PR keeps a version gate and makes it finer, adding a patch-level MACOS_27_0_1 cutoff. Neither the author nor @ malfet has replied. Any later release that brings the bug back would again give silently wrong mm results until someone finds it. Either make the change @ Isalia20 asked for (set has_stride_zero_mm_bug unconditionally), or reply in the thread and explain why t
| { include: [ | ||
| { config: "test_mps", shard: 1, num_shards: 1, runner: "macos-m1-15" }, | ||
| { config: "test_mps", shard: 1, num_shards: 1, runner: "macos-m2-26" }, | ||
| { config: "test_mps", shard: 1, num_shards: 1, runner: "macos-m2-27" }, |
There was a problem hiding this comment.
🔴 Blocker: the new runner label macos-m2-27 breaks the naming standard. It has no provider, and it doesn't use the {os}, {arch}{vendor}, {vcpu} or {memory} fields. It doesn't match ^(c-)?(mt|lf|am|in|nv|ib)-(rel-)?\[lwm\]-b?(x86|arm64g\[234\])-$. No other CI in this repo uses it; the only other hits are this PR's added lines and the .github/actionlint.yaml allowlist, which doesn't count. The standard can't express Apple Silicon, so you can't fix this by picking a better name. The canonical runner_naming_convention.md in pytorch/ci-infra has to be extended first, and the runner de
There was a problem hiding this comment.
This is non-sense. Let me take an action to fix this
@Isalia20 Pls take a look, I have gated this on 27.0.0 accordingly. I'm aiming for a minimal surgical gate only for 27.0.0 here, let me know if you have a different approach in mind. |
|
@pytorchbot merge -f 'MPS jobs have passed' |
Merge startedYour change will be merged immediately since you used the force (-f) flag, bypassing any CI checks (ETA: 1-5 minutes). Please use Learn more about merging in the wiki. Questions? Feedback? Please reach out to the PyTorch DevX Team |
…naming check The self-hosted macOS fleets are EC2 Mac pet instances, not OSDC, and the naming standard cannot express Apple Silicon, so every new macOS label (e.g. macos-m2-27 on pytorch#201517) was an unfixable blocker. Keep them in scope, but define their own form, matching what the runner install playbook derives on each Mac: macos-<chip>-<macOS major> plus a per-chip -stable alias, ^macos-m[1-9][0-9]*-([1-9][0-9]|stable)$. New chips and macOS releases (macos-m2-27, macos-m4-27) pass with no further edits; malformed macOS labels are still flagged.
…runner naming check The self-hosted macOS fleets are not on OSDC yet and keep their legacy labels until they migrate, so flagging every new one (e.g. macos-m2-27 on pytorch#201517) as a blocker was wrong. Keep them in scope, but accept their legacy form, matching what the runner install playbook derives on each Mac: macos-<chip>-<macOS major> plus a per-chip -stable alias, ^macos-m[1-9][0-9]*-([1-9][0-9]|stable)$. New chips and macOS releases pass with no further edits; malformed macOS labels are still flagged. Also drop Apple Silicon from 'Hardware the Standard Cannot Express': the canonical naming doc has os=m for macOS, and the macOS labels are legacy, not inexpressible.
…naming check The self-hosted macOS fleets are not OSDC runners and use their own label convention, so flagging every new one (e.g. macos-m2-27 on pytorch#201517) as a blocker was wrong. Keep them in scope, but accept their form, matching what the runner install playbook derives on each Mac: macos-<chip>-<macOS major> plus a per-chip -stable alias, ^macos-m[1-9][0-9]*-([1-9][0-9]|stable)$. New chips and macOS releases pass with no further edits; malformed macOS labels are still flagged. Also drop Apple Silicon from 'Hardware the Standard Cannot Express': the canonical naming doc already has os=m for macOS.
…naming check The self-hosted macOS fleets are not OSDC runners and use their own label convention, so flagging every new one (e.g. macos-m2-27 on pytorch#201517) as a blocker was wrong. Keep them in scope, but accept their form, matching what the runner install playbook derives on each Mac: macos-<chip>-<macOS major> plus a per-chip -stable alias, ^macos-m[1-9][0-9]*-([1-9][0-9]|stable)$. New chips and macOS releases pass with no further edits; malformed macOS labels are still flagged. Also drop Apple Silicon from 'Hardware the Standard Cannot Express': the canonical naming doc already has os=m for macOS.
…201566) ✴️ iz2: The automated review cut inline findings off mid-sentence at 600 characters: `extract_verdict.py` caps each finding message there, and stage B was never told about the limit. 18 of the 32 most recent bot inline comments hit the cap. Example: #201517 (comment) - `MAX_MESSAGE` goes from 600 to 1500, the same as `MAX_SUMMARY`. - The stage B prompt asks for at most 1200 characters per finding message, counting each `&`, `<` and `>` as five, since escaping lengthens them. - A message that still overflows ends in ` ...` at a word boundary. The input slice and the output cut both drop the token they split. `neutralize_message()` then drops trailing tokens until the result passes the publish check (`is_neutral_prose`). If no prefix passes, it returns empty, and the existing empty-message drop applies. A message that fails the check as a whole (for example, a blob that `neutralize()` joins) is not trimmed: it is still dropped as `failed_publish_check`. - A contract test keeps the prompt's budget at or below 80% of `MAX_MESSAGE`, and tests cover the cut cases. At the new cap, a review with 25 findings stays well under GitHub's body limit, and `MAX_BODY` still drops whole findings and says so when needed. Dr.CI's renderer has its own findings budget (`PR_REVIEW_FINDINGS_BUDGET`) and reports any findings it hides. Test plan: `python3 -m unittest discover -s scripts/pr_review -p 'test_*.py'` (452 tests pass). Pull Request resolved: #201566 Approved by: https://github.com/d4l3k
…naming check The self-hosted macOS fleets are not OSDC runners and use their own label convention, so flagging every new one (e.g. macos-m2-27 on pytorch#201517) as a blocker was wrong. Keep them in scope, but accept their form, matching what the runner install playbook in pytorch-gha-infra derives on each Mac: macos-<chip>-<macOS major> plus a per-chip -stable alias, ^macos-m[1-9][0-9]*-([1-9][0-9]|stable)$. New chips and macOS releases pass with no further edits; malformed macOS labels are still flagged.
…naming check The self-hosted macOS fleets are not OSDC runners and use their own label convention, so flagging every new one (e.g. macos-m2-27 on pytorch#201517) as a blocker was wrong. Keep them in scope, but accept their form, matching what the runner install playbook in pytorch-gha-infra derives on each Mac: macos-<chip>-<macOS major> plus a per-chip -stable alias, ^macos-m[1-9][0-9]*-([1-9][0-9]|stable)$. New chips and macOS releases pass with no further edits; malformed macOS labels are still flagged.
…naming check (#201579) The pr-review runner naming check (`.agents/skills/pr-review/ci-runner-naming.md`, from #199315) flags every new self-hosted macOS label as a blocker. That's how `macos-m2-27` was flagged on #201517. But these runners aren't OSDC runners, and their `macos-m*` labels follow their own convention. This PR keeps them in scope and accepts their form. It matches how the runner install playbook in pytorch-gha-infra builds the label on each Mac: ``` ^macos-m[1-9][0-9]*-([1-9][0-9]|stable)$ # macos-<chip>-<macOS major>, plus a per-chip -stable alias ``` - New section "Self-Hosted macOS Labels" with the form - "Checking a Label", step 3: validate `macos-m*` labels against that form, not the OSDC full form or length rule - "What to Report": for a malformed `macos-m*` label, suggest a name in the macOS form (these runners are set up by pytorch-gha-infra, not ci-infra), and scope the Apple Silicon entry in "Hardware the Standard Cannot Express" to OSDC-form labels New chips and macOS releases pass with no further edits, and malformed macOS labels are still flagged. Every `macos-m*` label in `.github` today (`macos-m1-15`, `macos-m1-stable`, `macos-m2-26`, `macos-m2-27`) matches. The reviewer loads this file from `main`, so the change applies to reviews after it lands. No test changes are needed: `test_workflow_contract.py` pins which files are hashed, not what they contain. Pull Request resolved: #201579 Approved by: https://github.com/izaitsevfb, https://github.com/jeanschmidt
Follow-up to #201231. The
mac2-m2pro.metalfleet shift in pytorch/test-infra#8964 is deployed:macos-m2-26(macOS 26) has 28 runners, up from 8macos-m2-27(macOS 27) has 8 runnersThis undoes the temporary pause from #201231 and adds macOS 27 coverage:
trunk.yml: re-add thempsshard onmacos-m2-26inductor-perf-test-nightly-macos.yml: restore the nightlyschedule(0 7 * * *)mac-mps.yml: addtest_mpsonmacos-m2-27, so MPS runs onmacos-m1-15,macos-m2-26andmacos-m2-27(macOS 15 / 26 / 27)actionlint.yamland the pr-review runner-naming list: addmacos-m2-27As of 2026-10-20 04:00 UTC, all 28
macos-m2-26and 8macos-m2-27runners are registered and online.macOS 27.0.0 fix. The new
macos-m2-27job surfaced a real bug:test_mm_stride_zerofailed on the macOS 27.0.0 runners, with 960/1024 elements wrong. That's the #180201 symptom, where MPSGraph matmul with stride-0 inputs computes only every 16th row. Apple fixed it in 26.4, but it's back in 27.0.0, and 27.0.1 and 27.2 are fine (thanks @Isalia20).mmonly applied the contiguify workaround on macOS < 26.4. This PR adds a patch-levelMacOSVersion::MACOS_27_0_1and widens the gate to< 26.4 || 27.0.0. Behaviour on every other macOS version is unchanged, and onlymmwith non-complex stride-0 inputs is affected.