Repository navigation
gpu-gates: (pg) plans card experts on a machine that counts their route scratch, and reads the drafted plan's room from MtpPlan - #255
Conversation
…te scratch, and reads the drafted plan's room from MtpPlan The paged clause planned on a machine that did not count the card experts' route scratch; it now plans with machine_for_experts(.., Experts::Card), as the load does. Its fit read the drafted plan's stage-card headroom, which leaves the draft's reserve R out: the expert rule moves experts off the card to make room for R, so that field rose and the clause read the rise as less room (A6000 real: -2,843,738,112 B). The fit now reads MtpPlan::headroom_bytes, which subtracts R, against the plain plan's stage-card headroom, and holds the relation term by term: equal fixed terms (dense, KV, stage rows, scratch, context, reserves), the planner's identity MtpPlan = T.headroom + T.reserves - R, and a remainder R - moved (moved: the expert and rounding bytes the rule took off the card) under the largest layer's one-expert card bytes plus a granule for each routed stack. The remainder's sign follows the packing at the room (A6000 real: +2,091,180 B at one room, -2,103,124 B at another), so which plan holds less room is printed, not required. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
There was a problem hiding this comment.
Verdict: CLEAN: The revised gate uses the planner's draft reserve and checks its headroom relation without requiring a packing-dependent sign.
Checked
Duplicates: 1 new callable (fixed) checked; no duplicate owner. No new named functions, types or constants; no dryer pairs reported.
Complexity: drafted_paged_run rose from 31 to 36 through branches that derive the per-layer packing bound in the existing clause.
Silent failure: 3 sites followed. Non-layer tensors and empty expert lists do not contribute; Stages::new rejects the zero-layer case before the maximum's fallback can run.
Tests: removing reserve from crates/model/src/arch/qwen35moe/place.rs:807 makes the new identity false, and fit reaches the gate result. Mutation checked by inspection; the PR reports killed reserve and old-field mutants.
Gates: the replaced inequality carries PIN(2026-10-15), its reason and evidence for both remainder signs. No production hot path changes.
Escape catalog: no C1–C4 patterns match.
Notes
Diagnostics report that dryer did not run. GPU gates were not run during this review. The reported card run lacks the required nvidia-smi card/driver line and a complete base/head/model witness; GPU evidence is false.
Card check: needs-gpu. This pull request changes crates/gpu-gates/src/bin/gate_qwen4exp_mtp.rs and carries no gate run on a card (CONTRIBUTING's evidence list); a maintainer adds gpu-verified after one.
🔨 Shingler, bloomery's review bot: approves a clean pull request and requests changes on a must-fix (how it works)
The status names 0.3.3's MiniCPM-V 4.7 images and the two Qwen3.8 fixes, and points at the release notes for the release pass. The known issues drop the two 0.3.2 lines fixed in #121 and #255 and add the split clause's run to run distance. The tarball names and release link are 0.3.3's. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
gate-gpu-qwen4exp-mtp's(pg)clause (a set draft on a paged plan) was red on the A6000 real tier, the 0.3.2 known issue q38pg. The red was in the clause's reading, not in the plan. This PR does two things:What
drafted_paged_runnow plans withmachine_for_experts(.., Experts::Card), as the load does. That machine counts the card experts' route scratch. This is the WIP fix carried from branch q38pg (ff1e0aea).headroom_byteswith the plain plan's.extra.MtpPlan::headroom_bytes, which subtracts R, against the plain plan's stage-card headroom (the plain-side partner). It also holds the relation term by term:MtpPlan::headroom = T.headroom + T.reserves − R.R − movedis bounded.movedis the expert and rounding bytes the rule took off the card. The bound is the largest layer's one-expert card bytes, read from the plain plan's card segments, plus one granule for each routed stack. The rule moves whole experts, so this is its slack.공통화한 것 (Commonized)
extra, the same numberplan_mtp_withreserves. It is not recomputed.Evidence
Pre-review CLEAN at e62bf8ff493d7538da3d4e72b94a4a5a05808736.GRANULEis aNonZeroU64, and R must include the draft arena.(pg) the plain plan's 14601420800 card expert bytes are not 4659 equal experts. This file's layers differ in per-expert bytes, and the bound now takes the largest layer.PIN(2026-10-15)line above the fit carries the evidence: remainder +2,091,180 B at room 30,796,775,936 (fde6499) and −2,103,124 B at room 31,139,464,192 (cee6e7e4).just gate-gpu-qwen4exp-mtpat e62bf8f (job s698):gpu-gate.sh: gate_qwen4exp_mtp ran 243 s (exit 0).(pg) room 30608413696 B: … the drafted plan's headroom 1077197076 B (MtpPlan) against the plain plan's 1075093952 B, -2103124 B less (the drafted plan holds less: false, printed); R 2845829292 B, moved 2847932416 B, remainder -2103124 B (bound 10285056); fixed terms equal true, identity true PASS(pg) the drafted run's 32 ids = the plain run's PASS …tools/mutant-run.sh):r = 0, s680):… identity false FAIL, killed.boxq.py attachafter a daemon blip): red. That inequality is false whenever the identity holds, because the stage card's headroom is the MtpPlan headroom plus R.tools/mac-remote.sh --tree <a clean copy of cee6e7e4> origin/main, d1-mac):tools/review/local.py --self-test(--full with a validator that wrote nothing ends 65: 70 … git archive | tar failed). That tool is main's and is untouched here; gpu, model, gpu-gates, tools: the common pieces a Nemotron-H card body attaches to #235's body records the same Mac-only red.specs/common/q38pg-pg-options.mdis marked "chosen: B".🤖 Generated with Claude Code