d3d12: the memory hook names its own placeholder holes so the guards' walk stops re-asking them under Wine (D3D12-WATCH-PLACEHOLDER-NAMES) #3256

Open
github-bot wants to merge 21 commits from github-bot/gh-3256 into main AGit
Owner

@⁠z3r0rc on GitHub · 2026-12-02 22:46 UTC · original
z3r0rc:d3d12-watch-placeholder-names → main · +2371 −183 · 7 files · 21 commits · open

Claimed in the coordination issue as: D3D12-WATCH-PLACEHOLDER-NAMES — claim comment #2570 (comment-7360919453).

Depends on: #2896 and #3154 (this builds on neither, but overlaps both textually — see "Relation to open work"; whoever lands second rebases).

Coordination: claim in #2570, "D3D12-WATCH-PLACEHOLDER-NAMES".

Problem, measured. Under Wine the guards' per-frame walk of a guarded range asks the kernel
about every hole region it cannot name. For a hole of the runtime's own xmem reservations —
reserved without commit, later partly committed — Wine's kernel answers the placeholder probe
with nothing, so the region stays unnamed forever and the walk re-asks it every pass. Census
counters on a steady world (RTX 4090, Wine 11.23, same exe A/B on the arm alone) show a median
of 11,428 hole questions a frame with the name off and 2 with it on; offline a mapped-block
asking prices ~900-2,000 ns, sizing the family at 3.5-9.3 ms of submitting-thread CPU a frame.
The fps delta did not rise above scene variance in the windows run; the claim here is the
removed storm and the pinned geometry, not a frame-time number.

The fix says the word the kernel will not:

  • watch.rs gains a PLACEHOLDERS bit registry and a new notice,
    title_memory_placeholder(at, len); placeholder(block) becomes hook-named OR the old
    kernel probe — the fallback stays exactly as it was and the first touch of a range still
    goes through it.
  • xmem names its own uncommitted reservations (MEM_RESERVE without MEM_COMMIT: the
    64 KiB arena and the 0x42000 heap) at the VirtualAlloc it wraps, and re-names blocks at
    its hide and single-page re-hole sites, where a block becomes a hole again.
  • The four watch-side entry points that see memory come, change or go clear the name there —
    including a len-0 title_memory_freed, which is how both of the hook's releases say it.
  • LEONIDA_PLACEHOLDER_HOOK=0 (fixture-pinned to the walk's re-ask) makes it A/B-able in
    one binary.

New tallies split kernel askings from guard-walk questions on the asking line and name the
hook-named population, so the family stays measurable; an acceptance pin fixes the shape of
views_of's answer (one entry per page asked, in order, never deduped or joined) because a
consumer that wants spans joined joins them itself.

Offline fixtures, all green under Wine with no GPU and no game files:

  • the ask budget of a refresh: a view over clean pages asks nothing per pass; a hole run
    asks once — questions follow REGIONS, not blocks;
  • two ADJACENT placeholder runs ask twice, one two-block run once (pinned portable with a
    placeholder-naming probe so a real Windows box never false-fails where the kernel answers);
  • the partial-fill case: of two adjacent regions the heap takes ONE back with no word to the
    runtime — the refresh must report it ALONE, keep the neighbour a hole it asks about once,
    guard neither and publish nothing;
  • the payoff: passes 1..3 over hook-named holes ask NOTHING, the registry rotation stays
    bounded with its warning pinned silent, and the runtime's own word (an unmap or commit)
    re-arms the re-ask through the walk;
  • RED-by-graft: dropping the hook's word fails the seating pin (0 vs 2); a naive adjacency
    merge fails the partial-fill pin; trusting unnamed holes as held fails the first pass.

Tested with cargo xwin test -p leonida-gpu --features diagnostics,dlss --target x86_64-pc-windows-msvc under Wine 11.23: 788 passed / 5 failed / 70 ignored, and the
5 failures are the SAME tests that fail on bare current main in a control run of the
unmodified base (779 passed / 5 failed / 60 ignored) — Wine-environment placeholder, overlay-
and stack-walk families, none touched by this branch; the branch adds 9 passing tests and no
new failures. leonida-hle: 247 passed / 2 failed, matching the base. The 11,428 -> 2 census
was measured same-exe A/B on the counter arm alone in a logged window. Separately, operator
play windows on this exact build (arm on, then arm off via LEONIDA_PLACEHOLDER_HOOK=0):
clean exits, no device faults, no visual regressions, no difference noticed in play.

Relation to open work (complementary purpose, real textual overlap — whoever lands second
rebases): #2896 edits title_memory_freed/title_memory_changed and the standing-ask tests
(rest-state clearing on unmap/free); #3154 edits xmem.rs's allocation path (title address
range below 2^37).

GPUs tested: n/a — no GPU tests in this change (pure CPU/offline fixtures); the live census
windows ran on RTX 4090 (AD102), NVIDIA proprietary driver 620.73.04, CachyOS x86_64,
Wine 11.23, vkd3d-proton master.

AI-assisted: yes — an OpenCode coding agent (Qwen3.8-Flash-Next 125B, locally quantized IQ3_S
pack) under a human operator; the diff, fixtures and red/green evidence were additionally
audited by a separate read-only reviewer agent before posting. No game content anywhere.

  • Based on current main and merges cleanly.
  • One topic; follow-up work goes in a new pull request.
  • No game data, keys or decryption (CONTRIBUTING.md), including in logs or reports quoted here.
**@⁠z3r0rc** on GitHub · 2026-12-02 22:46 UTC · [original](https://github.com/ProjectLeonida/mandy/pull/3256) `z3r0rc:d3d12-watch-placeholder-names` → `main` · +2371 −183 · 7 files · 21 commits · open Claimed in the coordination issue as: `D3D12-WATCH-PLACEHOLDER-NAMES` — claim comment #2570 (comment-7360919453). Depends on: #2896 and #3154 (this builds on neither, but overlaps both textually — see "Relation to open work"; whoever lands second rebases). Coordination: claim in #2570, "D3D12-WATCH-PLACEHOLDER-NAMES". Problem, measured. Under Wine the guards' per-frame walk of a guarded range asks the kernel about every hole region it cannot name. For a hole of the runtime's own `xmem` reservations — reserved without commit, later partly committed — Wine's kernel answers the placeholder probe with nothing, so the region stays unnamed forever and the walk re-asks it every pass. Census counters on a steady world (RTX 4090, Wine 11.23, same exe A/B on the arm alone) show a median of 11,428 hole questions a frame with the name off and 2 with it on; offline a mapped-block asking prices ~900-2,000 ns, sizing the family at 3.5-9.3 ms of submitting-thread CPU a frame. The fps delta did not rise above scene variance in the windows run; the claim here is the removed storm and the pinned geometry, not a frame-time number. The fix says the word the kernel will not: - `watch.rs` gains a `PLACEHOLDERS` bit registry and a new notice, `title_memory_placeholder(at, len)`; `placeholder(block)` becomes hook-named OR the old kernel probe — the fallback stays exactly as it was and the first touch of a range still goes through it. - `xmem` names its own uncommitted reservations (`MEM_RESERVE` without `MEM_COMMIT`: the 64 KiB arena and the 0x42000 heap) at the `VirtualAlloc` it wraps, and re-names blocks at its hide and single-page re-hole sites, where a block becomes a hole again. - The four watch-side entry points that see memory come, change or go clear the name there — including a len-0 `title_memory_freed`, which is how both of the hook's releases say it. - `LEONIDA_PLACEHOLDER_HOOK=0` (fixture-pinned to the walk's re-ask) makes it A/B-able in one binary. New tallies split kernel askings from guard-walk questions on the asking line and name the hook-named population, so the family stays measurable; an acceptance pin fixes the shape of `views_of`'s answer (one entry per page asked, in order, never deduped or joined) because a consumer that wants spans joined joins them itself. Offline fixtures, all green under Wine with no GPU and no game files: - the ask budget of a refresh: a view over clean pages asks nothing per pass; a hole run asks once — questions follow REGIONS, not blocks; - two ADJACENT placeholder runs ask twice, one two-block run once (pinned portable with a placeholder-naming probe so a real Windows box never false-fails where the kernel answers); - the partial-fill case: of two adjacent regions the heap takes ONE back with no word to the runtime — the refresh must report it ALONE, keep the neighbour a hole it asks about once, guard neither and publish nothing; - the payoff: passes 1..3 over hook-named holes ask NOTHING, the registry rotation stays bounded with its warning pinned silent, and the runtime's own word (an unmap or commit) re-arms the re-ask through the walk; - RED-by-graft: dropping the hook's word fails the seating pin (0 vs 2); a naive adjacency merge fails the partial-fill pin; trusting unnamed holes as held fails the first pass. Tested with `cargo xwin test -p leonida-gpu --features diagnostics,dlss --target x86_64-pc-windows-msvc` under Wine 11.23: 788 passed / 5 failed / 70 ignored, and the 5 failures are the SAME tests that fail on bare current `main` in a control run of the unmodified base (779 passed / 5 failed / 60 ignored) — Wine-environment placeholder, overlay- and stack-walk families, none touched by this branch; the branch adds 9 passing tests and no new failures. `leonida-hle`: 247 passed / 2 failed, matching the base. The 11,428 -> 2 census was measured same-exe A/B on the counter arm alone in a logged window. Separately, operator play windows on this exact build (arm on, then arm off via `LEONIDA_PLACEHOLDER_HOOK=0`): clean exits, no device faults, no visual regressions, no difference noticed in play. Relation to open work (complementary purpose, real textual overlap — whoever lands second rebases): #2896 edits `title_memory_freed`/`title_memory_changed` and the standing-ask tests (rest-state clearing on unmap/free); #3154 edits `xmem.rs`'s allocation path (title address range below 2^37). GPUs tested: n/a — no GPU tests in this change (pure CPU/offline fixtures); the live census windows ran on RTX 4090 (AD102), NVIDIA proprietary driver 620.73.04, CachyOS x86_64, Wine 11.23, vkd3d-proton master. AI-assisted: yes — an OpenCode coding agent (Qwen3.8-Flash-Next 125B, locally quantized IQ3_S pack) under a human operator; the diff, fixtures and red/green evidence were additionally audited by a separate read-only reviewer agent before posting. No game content anywhere. - [x] Based on current `main` and merges cleanly. - [x] One topic; follow-up work goes in a new pull request. - [x] No game data, keys or decryption (CONTRIBUTING.md), including in logs or reports quoted here.
(cherry picked from commit 3405fd003cdcd72b7101b28b04a07e40f6dc76fe)
(cherry picked from commit c54a33f4d5ae83a0a20de000a9c1c6408322fa8f)
(cherry picked from commit 8ab36733937e8de00163185213c61892a52507f9)
(cherry picked from commit 75c03d224faf41346d70a2516b500f74f7ad6508)
(cherry picked from commit c7c54942916cdb10458719273a99c44493453536)
(cherry picked from commit b156f84b382700d09d383de7db46a7e757b17e55)
(cherry picked from commit 96608e4db08a95fd5901efe75991cced83179654)
(cherry picked from commit 7c2fa6dac4a640d6847dcdb3451738a87ae7617e)
The V3 cap rig: six blocks, views at the ends, the middle four as FOUR adjacent
one-block placeholder regions, frame::test_advance() between refreshes. One
question per region per refresh, the whole range known every frame, and a
mid-range fill-in lands the same frame reported alone. The cap site for any
future per-frame budget is the walk, never the fill-in loop.
R-P1a: split the protection census (alias copystat, fallback runs booked).
R-P1b: the call-budget fixture - a streamed range mapped at its ends with
placeholders between must be guarded with the fewest protection calls the
shape allows; ASKS(22-25) pins, an ignored timing probe prices the four
call shapes.
R-N0 (note 0016 CA102): ASKS 26->30 - walk_questions/fallback_questions
plus their ns - every hole question booked at its site (guards' walk vs
protect_here's fallback) and timed; the census print splits the tail's
13.7k questions a frame and books their ms. The six ask-budget children
pin exact (walk, fallback) site tuples: a range's first touch is asked
by the fallback, every later frame's re-ask is the guards' walk; the
probe also prices the question itself (one VirtualQuery, 700-800 ns on
Wine), which sizes the walk at ~10 ms/frame on the ca97 tail.
A hole of OUR reservation answers nothing to the guards under Wine: the
kernel's class-7 probe never names a placeholder here, so ~11.7k hole
regions were re-asked VirtualQuery after VirtualQuery every frame at the
ca97 tail (CA102 sized the family at 3.5-9.3 ms/frame). Now the hook
says the word itself: watch.rs gains a PLACEHOLDERS bit registry and a
title_memory_placeholder notice; placeholder() = hook_named || old
kernel probe; xmem names its uncommitted reservations (PAGES_64K and
the 0x42000 heap) and re-names them at hide()/single-page re-holes; the
four watch-side entry points clear the name wherever memory comes,
changes or goes. First touch of a range stays the fallback's (CA102
site law), later frames ask nothing. New tally hook_named_holes seats
the payoff in the frame census. Pin: parent + per-process child
the_ask_budget_of_hook_named_holes — passes 1..3 ask NOTHING, rotation
bounded and its A2 warning pinned silent, unname-on-word brings the
re-ask back via the walk; RED-by-graft G4 (drop the hook's word:
seating pin left:0 right:2). Suite 785/3/68 = baseline +1/+1, same
three named Wine fails; hle 247/2 pre-existing; views_of untouched.
Reviewer blockers on N4 (ebd1964ce), fixed forward:
- title_memory_freed len==0 (how both xmem releases say it) now clears the
  PLACEHOLDERS registry across the whole allocation via resolve_end; before
  this a freed XMem reservation stayed named and the guards stopped asking
  about whatever replaced it.
- falsifier R-N4b landed: the_hook_named_fill_never_mentioned_by_the_runtime
  (+ parent) pins the staleness window HONEST (sees nothing), the rotation
  catching a no-word fill in exactly 2 calls, the next refresh SEEING it
  (reported written, foreign, published never).
- graft record corrected: the R-N4a kill was G1 not G4; clear-family grafts
  G4/G5/G6 now run, all RED at distinct pins (G6 at the new len-0-free pin =
  the blocker fix proven to bite); reverted green.
- len-0-free unname pin inside the R-N4a child: re-ask (9,14)=(2,2) with the
  freed block via the fallback, ASKS[30] delta 0.
Suites: leonida-gpu 786/3/69 (rig baseline +2, same three Wine fails,
...-130823.log); hle 247/2 unchanged. Regression gate: CA102/R1/R2 children
green with named==0 untouched. STATUS slimmed to 300 (parallel ca104 edits
pushed it over).
The reviewer's payoff-window note: the N4 counters evidence needs an A/B
against the SAME exe, so the lever gets an off arm. One read seat,
hook_named, covers all three xmem set sites at once; when off, the
registry is still written but never believed, placeholder() falls to the
kernel's (nothing under Wine) and every held hole goes back to the
guards' walk per frame.

Fixture pair the_off_arm_sends_the_hook_s_holes_back_to_the_kernel +
#[ignore] child the_ask_budget_of_the_placeholder_off_arm: the sibling's
exact eight-block shape, arm handed down through the child's environment;
pins hook_named==0 everywhere, first refresh (1,2,2,0)+(walk,fall)=(0,2)
with ASKS[30] delta 0, then every pass re-asks both holes by the WALK
(2,0) - the cost the lever removes. GREEN under Wine (the kernel names
nothing, printed honest).

Also the reviewer's diff-hygiene nit: a stray blank line inside
title_memory_allocated gone. switches.md regenerated (728 names scanned,
683 rows; the LEONIDA_PLACEHOLDER_HOOK row rides).

Suites: leonida-gpu 787/3/70 = rig baseline +1 parent +1 child, the same
three named Wine fails (rusttest-leonida-gpu-20261202-132537.log).
The table is generated from the code; the carried off arm adds
`LEONIDA_PLACEHOLDER_HOOK` and the widened ask tallies leave one
comment-only name (`LEONIDA_WATCH_BACKOFF`) in the "read nowhere" list.
github-bot locked as GitHub sync and limited conversation to collaborators 2026-12-02 22:52:16 +00:00
Author
Owner

@⁠merzleckeier on GitHub · 2026-12-02 22:53 UTC · original · reviewed

Test and merge scope check on e7aad1d4. The diff adds ten #[ignore] cases in watch.rs, matching the change from 60 to 70 ignored in the reported suite totals. The normal D3D12 workflow does not select ignored tests. Several comments point at fork/dev/rusttest.sh, which is absent from the PR tree. Could you document how a reviewer can run the relevant acceptance cases from a public checkout in separate processes, and include the exact-head results for those cases? The aggregate suite result does not verify the ignored cases.

I also checked that this head merges with main at 16243cd6, which already includes #3154. The other declared overlap is current: git merge-tree against #2896 at c9c6b103 conflicts in watch.rs.

**@⁠merzleckeier** on GitHub · 2026-12-02 22:53 UTC · [original](https://github.com/ProjectLeonida/mandy/pull/3256#pullrequestreview-6160476303) · **reviewed** Test and merge scope check on `e7aad1d4`. The diff adds ten `#[ignore]` cases in `watch.rs`, matching the change from 60 to 70 ignored in the reported suite totals. The normal D3D12 workflow does not select ignored tests. Several comments point at `fork/dev/rusttest.sh`, which is absent from the PR tree. Could you document how a reviewer can run the relevant acceptance cases from a public checkout in separate processes, and include the exact-head results for those cases? The aggregate suite result does not verify the ignored cases. I also checked that this head merges with `main` at `16243cd6`, which already includes #3154. The other declared overlap is current: `git merge-tree` against #2896 at `c9c6b103` conflicts in `watch.rs`.
Author
Owner

@⁠MoonEyes on GitHub · 2026-12-03 00:02 UTC · original

RUN (in game, batch of nine pull requests), each head merged with git merge --no-ff onto main 81efe4566, in one build: #3136 74bd1bcd4, #3156 53c3100ce, #3206 d024194b3, #3248 efd21d867, #3256 e7aad1d4c, #3262 3643c2879, #2851 b83b0b375, #3125 89bf1d328, #2642 164506d01. RTX 4060 8 GB, driver 610.88, Windows 11. Series S, -Resolution 1080, frame generation 2x, -PrecompileUsed, the same walking route as the other runs on this machine, 330 s after reaching the world.

What Result
Device lost / device removed 0
Exceptions, panics, hang watchdog, GPU stall, title suspended 0
Process alive at the end yes, stopped by the time limit
Rendered fps, last 240 s (48 samples) median 15.6, mean 15.6
Rendered fps, last 120 s median 14.3
Time under 5 fps in the world 3 %

For reference, the same machine and route rendered 13.3 to 17.2 fps on other batches in the last day. These fps are a check that nothing fell over, not a measurement of a gain.

Verdict: PASS for the in-game gate (300 s or more in the world, no device loss) for this batch, on the heads listed above. If one of these pull requests changes its head, this run no longer covers it.

Limits: one run; arrival in the world was driven by keys and not checked on pictures; -PrecompileUsed was used, so the default start (every known pipeline precompiled) was not exercised. The precompile before the world took 619 s, against 157 s for the previous batch; the shader-side changes in this batch (#3156, #3262) probably left the pipeline cache cold (not checked). Switches that are off by default (for example #2851's LEONIDA_TITLE_MEMORY_SCALE, #3136's timeline attribution) were not turned on: this run covers their default path only. #2642 targets Wine and was run on Windows only.

AI-assisted (Claude Code).

**@⁠MoonEyes** on GitHub · 2026-12-03 00:02 UTC · [original](https://github.com/ProjectLeonida/mandy/pull/3256#issuecomment-7362722014) RUN (in game, batch of nine pull requests), each head merged with `git merge --no-ff` onto main `81efe4566`, in one build: #3136 `74bd1bcd4`, #3156 `53c3100ce`, #3206 `d024194b3`, #3248 `efd21d867`, #3256 `e7aad1d4c`, #3262 `3643c2879`, #2851 `b83b0b375`, #3125 `89bf1d328`, #2642 `164506d01`. RTX 4060 8 GB, driver 610.88, Windows 11. Series S, `-Resolution 1080`, frame generation 2x, `-PrecompileUsed`, the same walking route as the other runs on this machine, 330 s after reaching the world. | What | Result | |---|---| | Device lost / device removed | 0 | | Exceptions, panics, hang watchdog, GPU stall, title suspended | 0 | | Process alive at the end | yes, stopped by the time limit | | Rendered fps, last 240 s (48 samples) | median 15.6, mean 15.6 | | Rendered fps, last 120 s | median 14.3 | | Time under 5 fps in the world | 3 % | For reference, the same machine and route rendered 13.3 to 17.2 fps on other batches in the last day. These fps are a check that nothing fell over, not a measurement of a gain. Verdict: PASS for the in-game gate (300 s or more in the world, no device loss) for this batch, on the heads listed above. If one of these pull requests changes its head, this run no longer covers it. Limits: one run; arrival in the world was driven by keys and not checked on pictures; `-PrecompileUsed` was used, so the default start (every known pipeline precompiled) was not exercised. The precompile before the world took 619 s, against 157 s for the previous batch; the shader-side changes in this batch (#3156, #3262) probably left the pipeline cache cold (not checked). Switches that are off by default (for example #2851's `LEONIDA_TITLE_MEMORY_SCALE`, #3136's timeline attribution) were not turned on: this run covers their default path only. #2642 targets Wine and was run on Windows only. AI-assisted (Claude Code).
Author
Owner

@⁠fiestorra on GitHub · 2026-12-03 00:12 UTC · original

VERIFY-3256 — Windows nativo: la documentación es exactamente lo que el generador escribe

Own commit e7aad1d4c — d3d12/docs/switches.md, 1 line (682 names → 683, a row for LEONIDA_PLACEHOLDER_HOOK)

For a generated document the only verification that means anything is this, and it passes:

python -I tools/d3d12_switches.py --out d3d12/docs/switches.md
  728 names written
sha256 before == after:  True
git diff after regenerating:  empty
python -I tools/d3d12_switches.py --check d3d12/docs/switches.md   exit 0

Regenerating from the branch's own sources produces a byte-identical file — so what is committed is what the generator writes, not a hand edit that happens to look right.

And that matters more than usual here, because the document says so itself: "No CI job keeps it up to date: run the command again, or --check, when you need it." A document that nothing keeps in sync is exactly the one that drifts, and this pull request is the drift being paid off.

What it documents — LEONIDA_PLACEHOLDER_HOOK=0 and a re-worded LEONIDA_ASK_GAP_KB row — comes from the branch's watch.rs, which is why the "time" of this review is the generator agreeing with the code.

What I could not test

  • The switches' behaviour: this is the index of them, not their effect.

Written with an AI assistant.

**@⁠fiestorra** on GitHub · 2026-12-03 00:12 UTC · [original](https://github.com/ProjectLeonida/mandy/pull/3256#issuecomment-7362926582) ## VERIFY-3256 — Windows nativo: **la documentación es exactamente lo que el generador escribe** | | | |---|---| | Own commit | `e7aad1d4c` — `d3d12/docs/switches.md`, 1 line (`682 names` → `683`, a row for `LEONIDA_PLACEHOLDER_HOOK`) | **For a generated document the only verification that means anything is this**, and it passes: ``` python -I tools/d3d12_switches.py --out d3d12/docs/switches.md 728 names written sha256 before == after: True git diff after regenerating: empty python -I tools/d3d12_switches.py --check d3d12/docs/switches.md exit 0 ``` **Regenerating from the branch's own sources produces a byte-identical file** — **so what is committed is what the generator writes, not a hand edit that happens to look right.** **And that matters more than usual here**, because **the document says so itself**: *"No CI job keeps it up to date: run the command again, or `--check`, when you need it."* **A document that nothing keeps in sync is exactly the one that drifts**, **and this pull request is the drift being paid off.** **What it documents** — `LEONIDA_PLACEHOLDER_HOOK=0` and a re-worded `LEONIDA_ASK_GAP_KB` row — **comes from the branch's `watch.rs`**, which is why the "time" of this review is the generator agreeing with the code. ## What I could not test - **The switches' behaviour**: this is the index of them, not their effect. Written with an AI assistant.
github-bot force-pushed github-bot/gh-3256 from e7aad1d4c3 to 61d8ed0aa0 2026-12-03 01:33:18 +00:00 Compare
Author
Owner

@⁠z3r0rc on GitHub · 2026-12-03 01:30 UTC · original

Both asks are fair, and the fix rides this push.

Running the ten cases from a public checkout. The tallies they pin are per-process, so each
case needs its own process; one command per case:

cargo test -p leonida-gpu --features diagnostics --target x86_64-pc-windows-msvc --no-run
# then, once per case, in its own process:
cargo test -p leonida-gpu --features diagnostics -- --ignored <case-name> -- --test-threads=1 --nocapture

(or run the built test binary the same way; under Wine — our runner uses Wine — the ten need no
device and no DXC staging; on Windows natively they use the real kernel APIs directly. Each
ignored case's own comment now names this command.)

One exception, and the reason on that case now says it: the_ask_budget_of_the_placeholder_off_arm
is a CHILD — it asserts the parent handed it LEONIDA_PLACEHOLDER_HOOK=0 before the first hook
read. Run its live parent the_off_arm_sends_the_hook_s_holes_back_to_the_kernel, which
re-runs the binary with that variable and echoes the child's numbers.

Exact-head results at 61d8ed0aa (rebased onto current main d5b30be1c; Wine 11.23): the
nine cases pass standalone; the parent above passes with its child's budget printed. Aggregates
at this head: gpu 801 passed / 5 failed / 70 ignored, hle 250 passed / 2 failed / 2 ignored —
all seven failures are the known Wine-substrate families (placeholder-naming trio, WARP overlay
"Invalid parameter", REMAP_HLSL d3dcompiler refusal, ws2_32 WSAConnectByList, xgamesave pair),
none new.

The head also moved e7aad1d4c → 61d8ed0aa: the rebase onto current main, plus a commit that
renames test attributes and docstrings to name the public run command (merzleckeier's ask), and
a comment-only sweep of internal note-IDs out of the sources. No behaviour change except the
LEONIDA_PLACEHOLDER_HOOK=0 off arm itself, which is inert unless the variable is set.

@⁠MoonEyes thanks for the batch run. The covered e7aad1d4c vs the new 61d8ed0aa differs by the
rebase onto current main (your 81efe4566 batch tree already ran our carried content), the
test-attribute renames, and comment scrubbing — no runtime behaviour change. Your PASS should
carry; but per your own caveat a moved head deserves its own stamp, so if you want to re-run,
say the word and we will hold the merge for it.

AI assistance disclosureAssisted by Qwen3.8-Flash-Next (OpenCode agent) per CONTRIBUTING.md; the runs above were driven by the agent under operator supervision.
**@⁠z3r0rc** on GitHub · 2026-12-03 01:30 UTC · [original](https://github.com/ProjectLeonida/mandy/pull/3256#issuecomment-7364413674) Both asks are fair, and the fix rides this push. **Running the ten cases from a public checkout.** The tallies they pin are per-process, so each case needs its own process; one command per case: ``` cargo test -p leonida-gpu --features diagnostics --target x86_64-pc-windows-msvc --no-run # then, once per case, in its own process: cargo test -p leonida-gpu --features diagnostics -- --ignored <case-name> -- --test-threads=1 --nocapture ``` (or run the built test binary the same way; under Wine — our runner uses Wine — the ten need no device and no DXC staging; on Windows natively they use the real kernel APIs directly. Each ignored case's own comment now names this command.) One exception, and the reason on that case now says it: `the_ask_budget_of_the_placeholder_off_arm` is a CHILD — it asserts the parent handed it `LEONIDA_PLACEHOLDER_HOOK=0` before the first hook read. Run its live parent `the_off_arm_sends_the_hook_s_holes_back_to_the_kernel`, which re-runs the binary with that variable and echoes the child's numbers. **Exact-head results** at `61d8ed0aa` (rebased onto current main `d5b30be1c`; Wine 11.23): the nine cases pass standalone; the parent above passes with its child's budget printed. Aggregates at this head: gpu 801 passed / 5 failed / 70 ignored, hle 250 passed / 2 failed / 2 ignored — all seven failures are the known Wine-substrate families (placeholder-naming trio, WARP overlay "Invalid parameter", REMAP_HLSL d3dcompiler refusal, ws2_32 `WSAConnectByList`, xgamesave pair), none new. The head also moved `e7aad1d4c` → `61d8ed0aa`: the rebase onto current main, plus a commit that renames test attributes and docstrings to name the public run command (merzleckeier's ask), and a comment-only sweep of internal note-IDs out of the sources. No behaviour change except the `LEONIDA_PLACEHOLDER_HOOK=0` off arm itself, which is inert unless the variable is set. @⁠MoonEyes thanks for the batch run. The covered `e7aad1d4c` vs the new `61d8ed0aa` differs by the rebase onto current main (your `81efe4566` batch tree already ran our carried content), the test-attribute renames, and comment scrubbing — no runtime behaviour change. Your PASS should carry; but per your own caveat a moved head deserves its own stamp, so if you want to re-run, say the word and we will hold the merge for it. <details><summary>AI assistance disclosure</summary>Assisted by Qwen3.8-Flash-Next (OpenCode agent) per CONTRIBUTING.md; the runs above were driven by the agent under operator supervision.</details>
Author
Owner

@⁠fiestorra on GitHub · 2026-12-03 01:54 UTC · original

Both asks are fair, and the fix riding this push is the right shape — thank you for taking them together rather than one and leaving the other.

What I will re-run when it lands (the same two commands, so the record is comparable):

python -I tools/d3d12_switches.py --out d3d12/docs/switches.md    → the file must come back byte-identical
python -I tools/d3d12_switches.py --check d3d12/docs/switches.md  → exit 0

The byte comparison is the one that matters for a generated document: "the generator writes what is committed" is a claim that can be tested on the tree, whereas "it looks right" cannot — and a --check that only counts names would pass over a row whose wording drifted.

And a note for the next person who regenerates it: --out rewrites the file in place, so running it and then git diff --stat is the whole check — no copy of the old file is needed. That is why I compared hashes rather than diffing against a saved copy.

**@⁠fiestorra** on GitHub · 2026-12-03 01:54 UTC · [original](https://github.com/ProjectLeonida/mandy/pull/3256#issuecomment-7364860739) **Both asks are fair, and the fix riding this push is the right shape** — **thank you for taking them together rather than one and leaving the other.** **What I will re-run when it lands** (the same two commands, so the record is comparable): ``` python -I tools/d3d12_switches.py --out d3d12/docs/switches.md → the file must come back byte-identical python -I tools/d3d12_switches.py --check d3d12/docs/switches.md → exit 0 ``` **The byte comparison is the one that matters for a generated document**: *"the generator writes what is committed"* **is a claim that can be tested on the tree**, **whereas "it looks right" cannot** — **and a `--check` that only counts names would pass over a row whose wording drifted.** **And a note for the next person who regenerates it**: **`--out` rewrites the file in place**, so **running it and then `git diff --stat` is the whole check** — **no copy of the old file is needed.** **That is why I compared hashes rather than diffing against a saved copy.**
Author
Owner

@⁠fiestorra on GitHub · 2026-12-03 01:54 UTC · original

Re-verified at 61d8ed0aa: still byte-identical, still --check 0

The push is here and it does what you said — the same two commands, on the new head:

python -I tools/d3d12_switches.py --out d3d12/docs/switches.md
  729 names written
sha256 before == after:   True
git diff after regenerating:  empty
python -I tools/d3d12_switches.py --check d3d12/docs/switches.md    exit 0

729 names now, against the 728 I measured on e7aad1d4c — so the push added a switch and regenerated the document with it, which is the right way round: the count moved because the source did, and the file is still exactly what the generator writes.

And the byte comparison is what makes that a statement rather than a hope: a hand edit that matched the count would pass a number check and fail this one.

From my side this is verified and I have nothing to ask. The one thing worth keeping for whoever regenerates it next is the procedure: --out then git diff --stat — an empty diff is the whole check, and no copy of the old file is needed.

**@⁠fiestorra** on GitHub · 2026-12-03 01:54 UTC · [original](https://github.com/ProjectLeonida/mandy/pull/3256#issuecomment-7364874530) ## Re-verified at `61d8ed0aa`: still byte-identical, still `--check` 0 **The push is here and it does what you said** — the same two commands, on the new head: ``` python -I tools/d3d12_switches.py --out d3d12/docs/switches.md 729 names written sha256 before == after: True git diff after regenerating: empty python -I tools/d3d12_switches.py --check d3d12/docs/switches.md exit 0 ``` **729 names now, against the 728 I measured on `e7aad1d4c`** — **so the push added a switch and regenerated the document with it**, **which is the right way round**: **the count moved because the source did, and the file is still exactly what the generator writes.** **And the byte comparison is what makes that a statement rather than a hope**: **a hand edit that matched the count would pass a number check and fail this one.** **From my side this is verified and I have nothing to ask.** **The one thing worth keeping for whoever regenerates it next is the procedure**: **`--out` then `git diff --stat` — an empty diff is the whole check, and no copy of the old file is needed.**
github-bot force-pushed github-bot/gh-3256 from 61d8ed0aa0 to a3ab0a50fa 2026-12-03 02:06:47 +00:00 Compare
Author
Owner

@⁠z3r0rc on GitHub · 2026-12-03 02:07 UTC · original

The red d3d12 (windows-latest) job was my bug, not the branch: a_write_through_another_view_is_reported_at_the_guarded_one read the diagnostics tallies without a feature gate, and ASKS is only compiled under diagnostics - so a plain cargo test --workspace --exclude xtask (no diagnostics) fails to compile the lib test with E0425. Every other census reading in this module is already gated behind the same feature; these readings leaked past it. The head moves to a3ab0a50faf648171ead8ad9bb68b6e1fb273f9e: the readings and the one assert over them are now gated like the rest, and the guard/alias behaviour that test pins is still exercised and asserted without the feature. I reproduced the job's exact command line offline before and after: red (E0425), green. Same head also replaces internal shorthand labels left in comments, assert messages and commit messages with plain English - no pin and no number changes; the only content deltas from the reviewed chain are the feature gate and that wording.

@⁠MoonEyes since the head moves, your earlier stamp is void - if the shape still looks right, a re-stamp would be appreciated.

**@⁠z3r0rc** on GitHub · 2026-12-03 02:07 UTC · [original](https://github.com/ProjectLeonida/mandy/pull/3256#issuecomment-7365117501) The red `d3d12 (windows-latest)` job was my bug, not the branch: `a_write_through_another_view_is_reported_at_the_guarded_one` read the diagnostics tallies without a feature gate, and `ASKS` is only compiled under `diagnostics` - so a plain `cargo test --workspace --exclude xtask` (no `diagnostics`) fails to compile the lib test with E0425. Every other census reading in this module is already gated behind the same feature; these readings leaked past it. The head moves to `a3ab0a50faf648171ead8ad9bb68b6e1fb273f9e`: the readings and the one assert over them are now gated like the rest, and the guard/alias behaviour that test pins is still exercised and asserted without the feature. I reproduced the job's exact command line offline before and after: red (E0425), green. Same head also replaces internal shorthand labels left in comments, assert messages and commit messages with plain English - no pin and no number changes; the only content deltas from the reviewed chain are the feature gate and that wording. @⁠MoonEyes since the head moves, your earlier stamp is void - if the shape still looks right, a re-stamp would be appreciated.
Author
Owner

@⁠MoonEyes on GitHub · 2026-12-03 03:00 UTC · original

RUN (in game, batch of two pull requests), each head merged with git merge --no-ff onto main d15e048a7, in one build: #3256 a3ab0a50f, #3278 63eb3d6e2. RTX 4060 8 GB, driver 610.88, Windows 11. Series S, -Resolution 1080, frame generation 2x, -PrecompileUsed, the same walking route as the other runs on this machine, 330 s after reaching the world.

What Result
Device lost / device removed 0
Exceptions, panics, hang watchdog, GPU stall, title suspended 0
Process alive at the end yes, stopped by the time limit
Rendered fps, last 240 s (48 samples) median 16.5, mean 16.6
Rendered fps, last 120 s median 16.1
Time under 5 fps in the world 0 %

For reference, the same machine and route rendered 13.3 to 17.2 fps on other batches in the last day. These fps are a check that nothing fell over, not a measurement of a gain.

Verdict: PASS for the in-game gate (300 s or more in the world, no device loss) for this batch, on the heads listed above. If one of these pull requests changes its head, this run no longer covers it.

Limits: one run; arrival in the world was driven by keys and not checked on pictures; -PrecompileUsed was used, so the default start (every known pipeline precompiled) was not exercised. #3256 was also run in a batch on its earlier head e7aad1d4c; this run covers its current head. #3278 changes what happens after a stall at the start; this run had no such stall (0 hang watchdog or GPU stall lines), so it shows the change leaves the usual start as it was, not that it mends the stalled one.

AI-assisted (Claude Code).

**@⁠MoonEyes** on GitHub · 2026-12-03 03:00 UTC · [original](https://github.com/ProjectLeonida/mandy/pull/3256#issuecomment-7366096819) RUN (in game, batch of two pull requests), each head merged with `git merge --no-ff` onto main `d15e048a7`, in one build: #3256 `a3ab0a50f`, #3278 `63eb3d6e2`. RTX 4060 8 GB, driver 610.88, Windows 11. Series S, `-Resolution 1080`, frame generation 2x, `-PrecompileUsed`, the same walking route as the other runs on this machine, 330 s after reaching the world. | What | Result | |---|---| | Device lost / device removed | 0 | | Exceptions, panics, hang watchdog, GPU stall, title suspended | 0 | | Process alive at the end | yes, stopped by the time limit | | Rendered fps, last 240 s (48 samples) | median 16.5, mean 16.6 | | Rendered fps, last 120 s | median 16.1 | | Time under 5 fps in the world | 0 % | For reference, the same machine and route rendered 13.3 to 17.2 fps on other batches in the last day. These fps are a check that nothing fell over, not a measurement of a gain. Verdict: PASS for the in-game gate (300 s or more in the world, no device loss) for this batch, on the heads listed above. If one of these pull requests changes its head, this run no longer covers it. Limits: one run; arrival in the world was driven by keys and not checked on pictures; `-PrecompileUsed` was used, so the default start (every known pipeline precompiled) was not exercised. #3256 was also run in a batch on its earlier head `e7aad1d4c`; this run covers its current head. #3278 changes what happens after a stall at the start; this run had no such stall (0 hang watchdog or GPU stall lines), so it shows the change leaves the usual start as it was, not that it mends the stalled one. AI-assisted (Claude Code).
github-bot force-pushed github-bot/gh-3256 from a3ab0a50fa to 7b7b261df1 2026-12-03 15:06:45 +00:00 Compare
Author
Owner

@⁠z3r0rc on GitHub · 2026-12-03 15:03 UTC · original

Head moved to 7b7b261df. What changed since a3ab0a50f: it is rebased on current main — the one conflict was the switch page against #3318's regeneration, and the code hunks are untouched (nothing upstream touched watch.rs/xmem.rs between the two bases); the switch page now comes from the #3318 generator, so the LEONIDA_PLACEHOLDER_HOOK row is produced, not hand-written (as #2642/#2643 do); the commit messages and a few code comments lost our internal shorthand, and the A/B fixture pair is renamed the_off_switch_* (comment and test-name lines only, nothing behavioural); and one counters slot this tree never writes was dropped. The in-game pass at a3ab0a50f carries over in substance, but the head move voids the review stamps — a fresh VERIFY on the new head would be welcome, and a re-run of the in-game batch when convenient. CI is re-running.

**@⁠z3r0rc** on GitHub · 2026-12-03 15:03 UTC · [original](https://github.com/ProjectLeonida/mandy/pull/3256#issuecomment-7382493005) Head moved to `7b7b261df`. What changed since `a3ab0a50f`: it is rebased on current main — the one conflict was the switch page against #3318's regeneration, and the code hunks are untouched (nothing upstream touched `watch.rs`/`xmem.rs` between the two bases); the switch page now comes from the #3318 generator, so the `LEONIDA_PLACEHOLDER_HOOK` row is produced, not hand-written (as #2642/#2643 do); the commit messages and a few code comments lost our internal shorthand, and the A/B fixture pair is renamed `the_off_switch_*` (comment and test-name lines only, nothing behavioural); and one counters slot this tree never writes was dropped. The in-game pass at `a3ab0a50f` carries over in substance, but the head move voids the review stamps — a fresh VERIFY on the new head would be welcome, and a re-run of the in-game batch when convenient. CI is re-running.
This pull request can be merged automatically.
This branch is out-of-date with the base branch
You are not authorized to merge this pull request.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin '+refs/pull/3256/head:github-bot/gh-3256'
git switch 'github-bot/gh-3256'

Merge

Merge the changes and update on Forgejo.
git switch 'main'
git merge --no-ff 'github-bot/gh-3256'
git switch 'github-bot/gh-3256'
git rebase 'main'
git switch 'main'
git merge --ff-only 'github-bot/gh-3256'
git switch 'github-bot/gh-3256'
git rebase 'main'
git switch 'main'
git merge --no-ff 'github-bot/gh-3256'
git switch 'main'
git merge --squash 'github-bot/gh-3256'
git switch 'main'
git merge --ff-only 'github-bot/gh-3256'
git switch 'main'
git merge 'github-bot/gh-3256'
git push origin 'main'
This discussion has been locked. Commenting is limited to contributors.
No reviewers
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
github/ubiquitarianism--leonida!3256
No description provided.