NVIDIA places: a test for the one bit the model takes from the driver #2887

Open
fiestorra wants to merge 1 commit from upstream-pr/2887 into main
fiestorra commented 2026-12-01 15:26:29 +00:00 (Migrated from github.com)

Imported from ubiquitarianism/leonida. Originally posted by fiestorra on 2026-12-01T15:26:29Z.


The four tests in pipeline/places/tests.rs are a model of one card and one driver — places.rs says which in its first lines, RTX 4060 Ti, 616.64 — and on an RTX 4090 with 621.24 all four fail, right after the first two assertions that do pass.

What they assert there and what the card says:

the_table_of_static_samplers
  left:  [0, 1, 2, ..., 15]
  right: [22, 20, 21, 0, 1, ..., 12]

And the printout from that same test, one step at a time:

host               : places 0 to 15 hold [0, 1, ..., 15]
host;make=22,20,21 : places 0 to 15 hold [0, 1, ..., 15]

So the sixteen do not slide. The model says they do, because a loaded pipeline gives its root signature back and its places with it, and the next three samplers take the lowest free ones. On 621.24 the loaded pipeline keeps them.

That one fact decides whether Places has to number the samplers at the start at all, and nothing in the code asks the driver for it — the model assumes one answer.

What this adds: a test that asks and reports the answer instead of asserting one.

It makes sixteen samplers, stores them, loads them back, makes three more after, and checks that places 0 to 15 hold either the sixteen they held (kept) or those three places on (given back), printing which. Both are answers a driver may give; on 621.24 it prints keeps its places and passes.

No existing assertion changes. The four that model 616.64 stay as they are, because with one driver measured, a test that accepted both would hide the change it should be reporting. When someone runs this on a card with 616.64, the new test prints gives back and the four keep failing — which is exactly the pair of facts needed to fix them, and it is now one command.

Measured:

cargo test -p leonida-gpu --lib                          631 passed  (37.5 s), 60 ignored
cargo test -p leonida-gpu --features diagnostics --lib places::tests::a_loaded_pipeline_keeps -- --ignored
  ok, prints "a loaded pipeline keeps its places: 0 to 15 hold [0, ..., 15]"
cargo clippy -p leonida-gpu --all-targets --features diagnostics   no warning in the file

The --ignored tests need a card and no game data: they make their own pipelines and read back what they wrote.

AI-assisted: yes — DeepSeek v4.1 (flash), on the card and the driver the model does not describe.

Written with an AI assistant.

Process, from the review

Claim: there is none in #2570 for this pull request, and I am not filing one retroactively to make the description look right. The review is right that it should have had the line; this is the state.

GPUs tested: n/a for the change itself - it is a test-only edit; the card it is about is named in the test's own output.

<!-- greyfinch-sync:ubiquitarianism/leonida:issue:5588815409 --> Imported from [ubiquitarianism/leonida](https://github.com/ProjectLeonida/mandy/pull/2887). Originally posted by [fiestorra](https://github.com/fiestorra) on 2026-12-01T15:26:29Z. --- **The four tests in `pipeline/places/tests.rs` are a model of one card and one driver — `places.rs` says which in its first lines, RTX 4060 Ti, 616.64 — and on an RTX 4090 with 621.24 all four fail, right after the first two assertions that do pass.** **What they assert there and what the card says:** ``` the_table_of_static_samplers left: [0, 1, 2, ..., 15] right: [22, 20, 21, 0, 1, ..., 12] ``` **And the printout from that same test, one step at a time:** ``` host : places 0 to 15 hold [0, 1, ..., 15] host;make=22,20,21 : places 0 to 15 hold [0, 1, ..., 15] ``` **So the sixteen do not slide.** **The model says they do, because a loaded pipeline gives its root signature back and its places with it, and the next three samplers take the lowest free ones.** **On 621.24 the loaded pipeline keeps them.** **That one fact decides whether `Places` has to number the samplers at the start at all, and nothing in the code asks the driver for it — the model assumes one answer.** **What this adds**: **a test that asks and reports the answer instead of asserting one.** **It makes sixteen samplers, stores them, loads them back, makes three more after, and checks that places 0 to 15 hold either the sixteen they held (`kept`) or those three places on (`given back`), printing which.** **Both are answers a driver may give; on 621.24 it prints `keeps its places` and passes.** **No existing assertion changes.** **The four that model 616.64 stay as they are, because with one driver measured, a test that accepted both would hide the change it should be reporting.** **When someone runs this on a card with 616.64, the new test prints `gives back` and the four keep failing — which is exactly the pair of facts needed to fix them, and it is now one command.** **Measured:** ``` cargo test -p leonida-gpu --lib 631 passed (37.5 s), 60 ignored cargo test -p leonida-gpu --features diagnostics --lib places::tests::a_loaded_pipeline_keeps -- --ignored ok, prints "a loaded pipeline keeps its places: 0 to 15 hold [0, ..., 15]" cargo clippy -p leonida-gpu --all-targets --features diagnostics no warning in the file ``` **The `--ignored` tests need a card and no game data**: **they make their own pipelines and read back what they wrote.** **AI-assisted:** yes — DeepSeek v4.1 (flash), on the card and the driver the model does not describe. Written with an AI assistant. ## Process, from the review **Claim**: there is none in #2570 for this pull request, and I am not filing one retroactively to make the description look right. The review is right that it should have had the line; this is the state. **GPUs tested**: n/a for the change itself - it is a test-only edit; the card it is about is named in the test's own output.
merzleckeier commented 2026-12-01 15:45:30 +00:00 (Migrated from github.com)

Imported from ubiquitarianism/leonida. Originally posted by merzleckeier on 2026-12-01T15:45:30Z.


I checked the new probe at a51b89ee + 0ff8a532f under Wine 11.22 / VKD3D-Proton 3.1.0, with the physical RTX 4070 SUPER (620.73.04) exposed to DXGI as vendor 0x10de. The VKD3D pipeline-library prerequisite is not met here. The stock probe fails at table.loaded with the driver’s disk cache disabled and again with a fresh enabled cache. On RADV the first readback succeeds and the test takes the expected non-NVIDIA exit.

A local log of the existing subprocess records shows plain made for both the save and the attempted reload on NVIDIA. The same outcome repeats when using the harness’s explicit plain PSO name and when enabling VKD3D’s pipeline_library_app_cache option. The readback is 0 through 15 in both processes, but the second pipeline was freshly made, so those values cannot classify the loaded pipeline on this host. This is diagnostic coverage of that prerequisite, without a native NVIDIA driver result. MEASURED with offscreen synthetic shaders. AI-assisted (Codex).

<!-- greyfinch-sync:ubiquitarianism/leonida:comment:7316456118 --> Imported from [ubiquitarianism/leonida](https://github.com/ProjectLeonida/mandy/pull/2887#issuecomment-7316456118). Originally posted by [merzleckeier](https://github.com/merzleckeier) on 2026-12-01T15:45:30Z. --- I checked the new probe at a51b89ee + 0ff8a532f under Wine 11.22 / VKD3D-Proton 3.1.0, with the physical RTX 4070 SUPER (620.73.04) exposed to DXGI as vendor 0x10de. The VKD3D pipeline-library prerequisite is not met here. The stock probe fails at table.loaded with the driver’s disk cache disabled and again with a fresh enabled cache. On RADV the first readback succeeds and the test takes the expected non-NVIDIA exit. A local log of the existing subprocess records shows plain made for both the save and the attempted reload on NVIDIA. The same outcome repeats when using the harness’s explicit plain PSO name and when enabling VKD3D’s pipeline_library_app_cache option. The readback is 0 through 15 in both processes, but the second pipeline was freshly made, so those values cannot classify the loaded pipeline on this host. This is diagnostic coverage of that prerequisite, without a native NVIDIA driver result. MEASURED with offscreen synthetic shaders. AI-assisted (Codex).
KelboLive commented 2026-12-01 17:32:28 +00:00 (Migrated from github.com)

Imported from ubiquitarianism/leonida. Originally posted by KelboLive on 2026-12-01T17:32:28Z.

Review: COMMENTED


Measured here on the same shape of machine (RTX 4070 Ti SUPER, 621.01): the new test passes 3/3 and prints keeps its places: 0 to 15 hold [0..15], and the four existing places tests fail exactly as the body describes (5 passed / 4 failed with --ignored) — that is genuinely useful evidence for the report.

But two claims do not hold:

  1. gave = 3..19 is not the 616.64 answer. The test's steps are byte-identical to the_table_of_static_samplers, whose 616.64 expectation is [22,20,21,0..12] (tests.rs:915, quoted in the body itself). On that driver this test will read that vector, print "gives back", and panic at tests.rs:969 rather than pass. Fix the branch to accept the observed 616.64 vector (or derive it from the same fixture).
  2. It does not test the model's bit. Running with LEONIDA_LIBRARY_STATIC_SAMPLERS=1 makes places::start return None (places.rs:1124-1131) and library_use take Use::Plain before consulting Places (:1168-1169), so short-circuiting Places::same to true leaves the test green — I verified it. And "nothing in the code asks the driver" is wrong: Places::check (places.rs:548-651) loads stored pipelines and compares them to made-now ones precisely to ask; what is not modelled is this perturbation (three samplers made before the load — the body says "after").

Also note the test only asserts its own two literals: changing kept from 0..16 to 3..19 does fail it, so the assertion is live, but nothing ties either literal to the model.

Either drive library_use/same and fix gave, or retitle it as a driver probe and drop the "nothing asks the driver" line. As an additive #[ignore]d diagnostic it is safe to merge; it just is not the test the title promises.

Merge is clean against current main (159 behind); the red check/linux-python-and-viewer jobs are the same inherited Python failures, unrelated to a Rust-only diff.

<!-- greyfinch-sync:ubiquitarianism/leonida:review:6136524819 --> Imported from [ubiquitarianism/leonida](https://github.com/ProjectLeonida/mandy/pull/2887#pullrequestreview-6136524819). Originally posted by [KelboLive](https://github.com/KelboLive) on 2026-12-01T17:32:28Z. **Review:** COMMENTED --- Measured here on the same shape of machine (RTX 4070 Ti SUPER, 621.01): the new test passes 3/3 and prints `keeps its places: 0 to 15 hold [0..15]`, and the four existing places tests fail exactly as the body describes (5 passed / 4 failed with `--ignored`) — that is genuinely useful evidence for the report. But two claims do not hold: 1. **`gave = 3..19` is not the 616.64 answer.** The test's steps are byte-identical to `the_table_of_static_samplers`, whose 616.64 expectation is `[22,20,21,0..12]` (`tests.rs:915`, quoted in the body itself). On that driver this test will read that vector, print "gives back", and **panic at `tests.rs:969`** rather than pass. Fix the branch to accept the observed 616.64 vector (or derive it from the same fixture). 2. **It does not test the model's bit.** Running with `LEONIDA_LIBRARY_STATIC_SAMPLERS=1` makes `places::start` return `None` (`places.rs:1124-1131`) and `library_use` take `Use::Plain` before consulting `Places` (`:1168-1169`), so short-circuiting `Places::same` to `true` leaves the test green — I verified it. And "nothing in the code asks the driver" is wrong: `Places::check` (`places.rs:548-651`) loads stored pipelines and compares them to made-now ones precisely to ask; what is not modelled is this perturbation (three samplers made *before* the load — the body says "after"). Also note the test only asserts its own two literals: changing `kept` from `0..16` to `3..19` does fail it, so the assertion is live, but nothing ties either literal to the model. Either drive `library_use`/`same` and fix `gave`, or retitle it as a driver probe and drop the "nothing asks the driver" line. As an additive `#[ignore]`d diagnostic it is safe to merge; it just is not the test the title promises. Merge is clean against current main (159 behind); the red `check`/`linux-python-and-viewer` jobs are the same inherited Python failures, unrelated to a Rust-only diff.
fiestorra commented 2026-12-01 17:58:12 +00:00 (Migrated from github.com)

Imported from ubiquitarianism/leonida. Originally posted by fiestorra on 2026-12-01T17:58:12Z.


Both hold, and thank you for measuring instead of reading - the second one especially, because I wrote "nothing in the code asks the driver" in a file whose check does exactly that, and I would have merged it.

The gave vector. You are right: 3..19 was never the 616.64 answer. The steps here are byte-identical to the_table_of_static_samplers's host;make=22,20,21, whose recorded answer is [22, 20, 21, 0..12], and on a card with 616.64 this probe would have printed "gives back" and then panicked on its own assertion. It now accepts that vector:

let gave: Vec<i32> = [22, 20, 21].into_iter().chain(0..13).collect();

The scope. Also right, and now said in the doc comment rather than denied: Places::check is what asks the driver at run time, and LEONIDA_LIBRARY_STATIC_SAMPLERS=1 takes Use::Plain before Places is consulted, so short-circuiting same leaves this green - as you verified. It measures the driver; the name is now a_loaded_pipeline_keeps_its_places_or_loses_them, and the "nothing asks the driver" line is gone.

"Before", not "after". The steps are host;make=22,20,21;pipe=c:0-15: the three are made before the sixteen are loaded back. The print line said "after it" and now says "before it". Same for the perturbation being what is not modelled.

What it still is: an additive #[ignore]d probe with no existing assertion touched, printing which of the two answers this card gives. What it is not: a test of the model, and the title no longer says it is.

Measured on the 4090 with 621.24 after the change:

cargo test -p leonida-gpu --features diagnostics --lib places::tests::a_loaded_pipeline
    -- --ignored --nocapture --test-threads=1
  ok, prints "a loaded pipeline keeps its places: 0 to 15 hold [0, ..., 15] ... before it"

Written with an AI assistant.

<!-- greyfinch-sync:ubiquitarianism/leonida:comment:7320163193 --> Imported from [ubiquitarianism/leonida](https://github.com/ProjectLeonida/mandy/pull/2887#issuecomment-7320163193). Originally posted by [fiestorra](https://github.com/fiestorra) on 2026-12-01T17:58:12Z. --- Both hold, and thank you for measuring instead of reading - the second one especially, because I wrote "nothing in the code asks the driver" in a file whose `check` does exactly that, and I would have merged it. **The `gave` vector.** You are right: `3..19` was never the 616.64 answer. The steps here are byte-identical to `the_table_of_static_samplers`'s `host;make=22,20,21`, whose recorded answer is `[22, 20, 21, 0..12]`, and on a card with 616.64 this probe would have printed "gives back" and then panicked on its own assertion. It now accepts that vector: ```rust let gave: Vec<i32> = [22, 20, 21].into_iter().chain(0..13).collect(); ``` **The scope.** Also right, and now said in the doc comment rather than denied: `Places::check` is what asks the driver at run time, and `LEONIDA_LIBRARY_STATIC_SAMPLERS=1` takes `Use::Plain` before `Places` is consulted, so short-circuiting `same` leaves this green - as you verified. It measures the driver; the name is now `a_loaded_pipeline_keeps_its_places_or_loses_them`, and the "nothing asks the driver" line is gone. **"Before", not "after".** The steps are `host;make=22,20,21;pipe=c:0-15`: the three are made before the sixteen are loaded back. The print line said "after it" and now says "before it". Same for the perturbation being what is *not* modelled. What it still is: an additive `#[ignore]`d probe with no existing assertion touched, printing which of the two answers this card gives. What it is not: a test of the model, and the title no longer says it is. Measured on the 4090 with 621.24 after the change: ``` cargo test -p leonida-gpu --features diagnostics --lib places::tests::a_loaded_pipeline -- --ignored --nocapture --test-threads=1 ok, prints "a loaded pipeline keeps its places: 0 to 15 hold [0, ..., 15] ... before it" ``` Written with an AI assistant.
Christopher-Sundeby commented 2026-12-01 18:09:57 +00:00 (Migrated from github.com)

Imported from ubiquitarianism/leonida. Originally posted by Christopher-Sundeby on 2026-12-01T18:09:57Z.


Verified on native Windows NVIDIA: RTX 5090 (Blackwell), driver 621.40, Windows 11, head 9dfe9b7af.

cargo test -p leonida-gpu --features diagnostics --lib pipeline::places -- --ignored --nocapture --test-threads=1: 5 passed, 4 failed (the same four as on the 4090 / 621.24).

  • The new probe passes and prints a loaded pipeline keeps its places: 0 to 15 hold [0, 1, ..., 15], the same answer as 621.24.
  • the_table_of_static_samplers prints host;make=22,20,21: places 0 to 15 hold [0, ..., 15], the same as 621.24.

One caveat on what "keeps" covers: the probe uses only compute pipelines (pipe=c:0-15). On this driver graphics pipelines still read through the stored places. This happened in every run (3 of 3, and 2 of 2):

a_stored_pipeline_reads_through_the_places_of_the_run_that_stored_it, "loaded after ten other samplers" (LEONIDA_LIBRARY_STATIC_SAMPLERS=1):
  s (LoadPipeline, compute)  read [6, 7]    wrong 0
  g (LoadGraphicsPipeline)   read [43, 44]  wrong 2
  c (LoadComputePipeline)    read [1, 2, 3] wrong 0

So on 621.40 (and likely 621.24, given the same failures) a loaded compute pipeline keeps its places and a loaded graphics pipeline does not. The probe's line is true for compute only. Suggestion: name it for compute, or add a pipe=g: twin.

This also has a runtime consequence, which I'm taking separately on #2570. Places::check probes with compute pipelines only, so on this driver it answers same when the places did shift, and a graphics pipeline is then loaded through the wrong samplers. In pipelines_with_static_samplers_come_from_the_library, at the step make=50,51;host;..., it reproduces 3 of 3: places: "same", and the g pipeline is loaded with read [2, 3] and wrong 2.

AI-assisted: yes (Claude Opus 5.5, via Claude Code).

<!-- greyfinch-sync:ubiquitarianism/leonida:comment:7320506477 --> Imported from [ubiquitarianism/leonida](https://github.com/ProjectLeonida/mandy/pull/2887#issuecomment-7320506477). Originally posted by [Christopher-Sundeby](https://github.com/Christopher-Sundeby) on 2026-12-01T18:09:57Z. --- Verified on native Windows NVIDIA: RTX 5090 (Blackwell), driver 621.40, Windows 11, head `9dfe9b7af`. `cargo test -p leonida-gpu --features diagnostics --lib pipeline::places -- --ignored --nocapture --test-threads=1`: 5 passed, 4 failed (the same four as on the 4090 / 621.24). - The new probe passes and prints `a loaded pipeline keeps its places: 0 to 15 hold [0, 1, ..., 15]`, the same answer as 621.24. - `the_table_of_static_samplers` prints `host;make=22,20,21: places 0 to 15 hold [0, ..., 15]`, the same as 621.24. One caveat on what "keeps" covers: the probe uses only compute pipelines (`pipe=c:0-15`). On this driver **graphics pipelines still read through the stored places**. This happened in every run (3 of 3, and 2 of 2): ``` a_stored_pipeline_reads_through_the_places_of_the_run_that_stored_it, "loaded after ten other samplers" (LEONIDA_LIBRARY_STATIC_SAMPLERS=1): s (LoadPipeline, compute) read [6, 7] wrong 0 g (LoadGraphicsPipeline) read [43, 44] wrong 2 c (LoadComputePipeline) read [1, 2, 3] wrong 0 ``` So on 621.40 (and likely 621.24, given the same failures) a loaded compute pipeline keeps its places and a loaded graphics pipeline does not. The probe's line is true for compute only. Suggestion: name it for compute, or add a `pipe=g:` twin. This also has a runtime consequence, which I'm taking separately on #2570. `Places::check` probes with compute pipelines only, so on this driver it answers `same` when the places did shift, and a graphics pipeline is then loaded through the wrong samplers. In `pipelines_with_static_samplers_come_from_the_library`, at the step `make=50,51;host;...`, it reproduces 3 of 3: `places: "same"`, and the `g` pipeline is loaded with `read [2, 3]` and `wrong 2`. AI-assisted: yes (Claude Opus 5.5, via Claude Code).
fiestorra commented 2026-12-01 18:13:42 +00:00 (Migrated from github.com)

Imported from ubiquitarianism/leonida. Originally posted by fiestorra on 2026-12-01T18:13:42Z.


The d3d12 (windows-latest) job is red on crash::tests::memory_at_names_what_an_access_hit, and it is not this branch:

thread 'crash::tests::memory_at_names_what_an_access_hit' panicked
  assertion `left == right` failed
    left:  "read-write"
    right: "nothing mapped there"

That test is d3d12/crates/leonida-loader/src/crash.rs:890, and the assertion that failed is crash.rs:915, assert_eq!(memory_at(base + 8), "nothing mapped there") - it maps a page and expects the eight bytes past it to be unmapped, which depends on where the runner's allocator put things. This pull request touches pipeline/places/tests.rs and nothing else, and its test is #[ignore]d, so that job does not run it at all.

Two things I could not do: gh run rerun --failed is refused for this account (Must have admin rights to Repository), so I cannot show it passing on a second attempt. That is the one piece of evidence missing, and it is a click someone else has.

The rest of the job's output is green, including pipeline::places itself in its non-ignored form.

Written with an AI assistant.

<!-- greyfinch-sync:ubiquitarianism/leonida:comment:7320603886 --> Imported from [ubiquitarianism/leonida](https://github.com/ProjectLeonida/mandy/pull/2887#issuecomment-7320603886). Originally posted by [fiestorra](https://github.com/fiestorra) on 2026-12-01T18:13:42Z. --- The `d3d12 (windows-latest)` job is red on `crash::tests::memory_at_names_what_an_access_hit`, and it is not this branch: ``` thread 'crash::tests::memory_at_names_what_an_access_hit' panicked assertion `left == right` failed left: "read-write" right: "nothing mapped there" ``` That test is `d3d12/crates/leonida-loader/src/crash.rs:890`, and the assertion that failed is `crash.rs:915`, `assert_eq!(memory_at(base + 8), "nothing mapped there")` - it maps a page and expects the eight bytes past it to be unmapped, which depends on where the runner's allocator put things. This pull request touches `pipeline/places/tests.rs` and nothing else, and its test is `#[ignore]`d, so that job does not run it at all. Two things I could not do: `gh run rerun --failed` is refused for this account (`Must have admin rights to Repository`), so I cannot show it passing on a second attempt. That is the one piece of evidence missing, and it is a click someone else has. The rest of the job's output is green, including `pipeline::places` itself in its non-ignored form. Written with an AI assistant.
Christopher-Sundeby commented 2026-12-01 18:18:47 +00:00 (Migrated from github.com)

Imported from ubiquitarianism/leonida. Originally posted by Christopher-Sundeby on 2026-12-01T18:18:47Z.


A correction to my comment above. On 621.40, compute pipelines are not always safe either. In a later run of pipelines_with_static_samplers_come_from_the_library, at its no-care step (=1, make=50,51 first), the stream-made compute pipeline also read through other samplers:

c read [1, 2, 3] wrong 0 | g read [2, 3] wrong 2 | s read [4, 5] wrong 2

In the earlier runs, s read [6, 7], which was right. So, measured on this card: a loaded graphics pipeline read wrong in every run, and loaded compute pipelines read right most of the time but not every time. "Keeps its places" holds for compute only, and only most of the time.

AI-assisted: yes (Claude Opus 5.5, via Claude Code).

<!-- greyfinch-sync:ubiquitarianism/leonida:comment:7320738708 --> Imported from [ubiquitarianism/leonida](https://github.com/ProjectLeonida/mandy/pull/2887#issuecomment-7320738708). Originally posted by [Christopher-Sundeby](https://github.com/Christopher-Sundeby) on 2026-12-01T18:18:47Z. --- A correction to my comment above. On 621.40, compute pipelines are not always safe either. In a later run of `pipelines_with_static_samplers_come_from_the_library`, at its no-care step (`=1`, `make=50,51` first), the stream-made compute pipeline also read through other samplers: ``` c read [1, 2, 3] wrong 0 | g read [2, 3] wrong 2 | s read [4, 5] wrong 2 ``` In the earlier runs, `s` read `[6, 7]`, which was right. So, measured on this card: a loaded graphics pipeline read wrong in every run, and loaded compute pipelines read right most of the time but not every time. "Keeps its places" holds for compute only, and only most of the time. AI-assisted: yes (Claude Opus 5.5, via Claude Code).
fiestorra commented 2026-12-01 18:19:35 +00:00 (Migrated from github.com)

Imported from ubiquitarianism/leonida. Originally posted by fiestorra on 2026-12-01T18:19:35Z.


One more piece of evidence for the comment above, and it settles it: the same workflow passed on this branch's previous head and failed on this one, with the only difference being the two corrections in the places test.

46703727105  D3D12 runtime  success  8f5c23f   (my first rebase)
46709274287  D3D12 runtime  failure  9dfe9b7   (after the corrections KelboLive asked for)

What changed between them is pipeline/places/tests.rs only: the gave vector, the test's name, and its doc comment. What failed is leonida-loader/src/crash.rs::memory_at_names_what_an_access_hit, at its memory_at(base + 8) assertion. A test in another crate, checking where the allocator put a page, cannot be reached by a change to an #[ignore]d test in pipeline.

So it is the runner's address layout, not this branch - and the run on 8f5c23f is the control that says so, which is the thing I could not produce by rerunning because this account cannot.

What would make it good to land anyway: the job's other 83 tests pass, pipeline::places is not among them (it is #[ignore]d), and the change is a probe that only prints.

Written with an AI assistant.

<!-- greyfinch-sync:ubiquitarianism/leonida:comment:7320763127 --> Imported from [ubiquitarianism/leonida](https://github.com/ProjectLeonida/mandy/pull/2887#issuecomment-7320763127). Originally posted by [fiestorra](https://github.com/fiestorra) on 2026-12-01T18:19:35Z. --- One more piece of evidence for the comment above, and it settles it: **the same workflow passed on this branch's previous head and failed on this one, with the only difference being the two corrections in the places test.** ``` 46703727105 D3D12 runtime success 8f5c23f (my first rebase) 46709274287 D3D12 runtime failure 9dfe9b7 (after the corrections KelboLive asked for) ``` **What changed between them** is `pipeline/places/tests.rs` only: the `gave` vector, the test's name, and its doc comment. **What failed is `leonida-loader/src/crash.rs::memory_at_names_what_an_access_hit`**, at its `memory_at(base + 8)` assertion. **A test in another crate, checking where the allocator put a page, cannot be reached by a change to an `#[ignore]`d test in `pipeline`.** **So it is the runner's address layout, not this branch** - and the run on `8f5c23f` is the control that says so, which is the thing I could not produce by rerunning because this account cannot. **What would make it good to land anyway**: **the job's other 83 tests pass, `pipeline::places` is not among them (it is `#[ignore]`d), and the change is a probe that only prints.** Written with an AI assistant.
NetZlash commented 2026-12-01 20:35:07 +00:00 (Migrated from github.com)

Imported from ubiquitarianism/leonida. Originally posted by NetZlash on 2026-12-01T20:35:07Z.


Native hardware validation of 9dfe9b7af6ab67aa300a26f150120e82b99878fd.

Hardware. NVIDIA RTX 4070 SUPER (Ada, 12 GiB), NVIDIA driver 621.40, native Windows 11 Pro x64 build 26200, Ryzen 7 9700X and 32 GB RAM. This was an isolated checkout with Rust/Cargo 1.98.1 and the diagnostic build. All fixtures use synthetic shaders and readbacks.

Revised probe. The stock simple-compute test passed three times. Three additional save/reload pairs each used a fresh application pipeline library. The first process created the PSO and wrote the library. A second process succeeded through LoadComputePipeline in forced plain mode. All three readbacks were [0, 1, ..., 15], matching the fresh controls. This tests the revised recipe, which puts the perturbation before reload and corrects the displaced vector described in the RTX 4070 Ti SUPER / 621.01 review. I did not run driver 616.64.

Additional forced-plain checks. I ran three fresh-library pairs for each of two recipes, with ten extra samplers after the host setup or two extra samplers before it. Every second process succeeded at the specified library entry points. The fresh controls were equivalent pipelines created in that same process.

Route Ten after host Two before host Fresh control
Simple compute, LoadComputePipeline [1, 2, 3] [1, 2, 3] [1, 2, 3]
Graphics, LoadGraphicsPipeline [43, 44] [2, 3] [4, 5]
Stream compute, LoadPipeline [6, 7] [6, 7] [6, 7]

Ada and Blackwell. On Ada, both graphics samples read the wrong sampler in all six loads. This reproduces the reported graphics mismatch on RTX 5090 (Blackwell) with 621.40. The stream-compute samples matched their controls in all six Ada loads. The 5090 follow-up observed intermittent stream-compute mismatches. My early recipe isolates the forced-plain portion of the combined test and starts with a fresh application library. Run order and cache history differ, so the stream-compute result is limited to these recipes. The tests cover the selected library routes with forced plain mode. Automatic Places::check, other drivers and in-game behavior remain outside their scope.

AI-assisted validation: Codex / GPT-6.2 Sol (gpt-6.2-sol).

<!-- greyfinch-sync:ubiquitarianism/leonida:comment:7324935360 --> Imported from [ubiquitarianism/leonida](https://github.com/ProjectLeonida/mandy/pull/2887#issuecomment-7324935360). Originally posted by [NetZlash](https://github.com/NetZlash) on 2026-12-01T20:35:07Z. --- Native hardware validation of `9dfe9b7af6ab67aa300a26f150120e82b99878fd`. **Hardware.** NVIDIA RTX 4070 SUPER (Ada, 12 GiB), NVIDIA driver 621.40, native Windows 11 Pro x64 build 26200, Ryzen 7 9700X and 32 GB RAM. This was an isolated checkout with Rust/Cargo 1.98.1 and the diagnostic build. All fixtures use synthetic shaders and readbacks. **Revised probe.** The stock simple-compute test passed three times. Three additional save/reload pairs each used a fresh application pipeline library. The first process created the PSO and wrote the library. A second process succeeded through `LoadComputePipeline` in forced plain mode. All three readbacks were `[0, 1, ..., 15]`, matching the fresh controls. This tests the revised recipe, which puts the perturbation before reload and corrects the displaced vector described in the [RTX 4070 Ti SUPER / 621.01 review](https://github.com/ProjectLeonida/mandy/pull/2887#pullrequestreview-6136524819). I did not run driver 616.64. **Additional forced-plain checks.** I ran three fresh-library pairs for each of two recipes, with ten extra samplers after the host setup or two extra samplers before it. Every second process succeeded at the specified library entry points. The fresh controls were equivalent pipelines created in that same process. | Route | Ten after host | Two before host | Fresh control | | --- | --- | --- | --- | | Simple compute, `LoadComputePipeline` | `[1, 2, 3]` | `[1, 2, 3]` | `[1, 2, 3]` | | Graphics, `LoadGraphicsPipeline` | `[43, 44]` | `[2, 3]` | `[4, 5]` | | Stream compute, `LoadPipeline` | `[6, 7]` | `[6, 7]` | `[6, 7]` | **Ada and Blackwell.** On Ada, both graphics samples read the wrong sampler in all six loads. This reproduces the [reported graphics mismatch on RTX 5090 (Blackwell) with 621.40](https://github.com/ProjectLeonida/mandy/pull/2887#issuecomment-7320506477). The stream-compute samples matched their controls in all six Ada loads. The [5090 follow-up](https://github.com/ProjectLeonida/mandy/pull/2887#issuecomment-7320738708) observed intermittent stream-compute mismatches. My early recipe isolates the forced-plain portion of the combined test and starts with a fresh application library. Run order and cache history differ, so the stream-compute result is limited to these recipes. The tests cover the selected library routes with forced plain mode. Automatic `Places::check`, other drivers and in-game behavior remain outside their scope. AI-assisted validation: Codex / GPT-6.2 Sol (`gpt-6.2-sol`).
fiestorra commented 2026-12-01 21:37:58 +00:00 (Migrated from github.com)

Imported from ubiquitarianism/leonida. Originally posted by fiestorra on 2026-12-01T21:37:58Z.


Red on d3d12 (windows-latest), and not this branch. Two measurements, so it does not get read as a flake:

  1. This branch's own previous head passed the same job (8f5c23f, an hour before), with only the two corrections in the places test between them.
  2. The test that failed here is in another crate — leonida-loader's crash::tests::memory_at_names_what_an_access_hit, at its memory_at(base + 8) assertion — and a change to an #[ignore]d test in pipeline cannot reach it.

The runner's WARP adapter is the common factor, and #2923 is the fix being proposed for it: the workspace tests run one per core against one WARP device, and this crate flakes about one run in eight that way (measured: 16 parallel runs, 2 failures in two different tests; --test-threads=1, 8 of 8 clean).

A third data point from tonight, on hardware: descriptor::host::tests::views_are_made_beside_the_heap_and_copied_in fails on main on an RTX 4090 with the same kind of message ("copied as it was made"). Also not this branch — but it is a real failure of the tree, reported in #2570.

Written with an AI assistant.

<!-- greyfinch-sync:ubiquitarianism/leonida:comment:7326553079 --> Imported from [ubiquitarianism/leonida](https://github.com/ProjectLeonida/mandy/pull/2887#issuecomment-7326553079). Originally posted by [fiestorra](https://github.com/fiestorra) on 2026-12-01T21:37:58Z. --- **Red on `d3d12 (windows-latest)`, and not this branch.** Two measurements, so it does not get read as a flake: 1. **This branch's own previous head passed the same job** (`8f5c23f`, an hour before), with only the two corrections in the places test between them. 2. **The test that failed here is in another crate** — `leonida-loader`'s `crash::tests::memory_at_names_what_an_access_hit`, at its `memory_at(base + 8)` assertion — **and a change to an `#[ignore]`d test in `pipeline` cannot reach it.** **The runner's WARP adapter is the common factor, and #2923 is the fix being proposed for it**: the workspace tests run one per core against one WARP device, and this crate flakes about one run in eight that way (measured: 16 parallel runs, 2 failures in two different tests; `--test-threads=1`, 8 of 8 clean). **A third data point from tonight, on hardware**: `descriptor::host::tests::views_are_made_beside_the_heap_and_copied_in` fails on `main` on an RTX 4090 with the same kind of message ("copied as it was made"). **Also not this branch** — but it is a real failure of the tree, reported in #2570. Written with an AI assistant.
fiestorra commented 2026-12-01 23:43:16 +00:00 (Migrated from github.com)

Imported from ubiquitarianism/leonida. Originally posted by fiestorra on 2026-12-01T23:43:16Z.


The red d3d12 (windows-latest) was not this change: it was crash::tests::memory_at_names_what, in crates/leonida-loader, which this branch does not touch.

---- crash::tests::memory_at_names_what assertion left == right failed left: "read-write" right: "nothing mapped there"

I could not make it fail here: six runs of cargo test -p leonida-loader --lib crash::tests on this machine, in parallel like CI, 19 passed, 0 failed, six times out of six. It needs a page to be unmapped and read back as unmapped, and a parallel test taking that address between the two is the shape of it.

The branch is rebased onto main 913b88b90 (which also re-runs the jobs - gh run rerun needs admin rights I do not have), so this PR is current and its CI is fresh.

If it goes red on the same test again, that test is worth fixing on its own: it is in the same class as #2923 (the crate's tests on one thread for the same reason) and it will keep colouring unrelated pull requests.

AI-assisted: yes - DeepSeek v4.1 (flash).

Written with an AI assistant.

<!-- greyfinch-sync:ubiquitarianism/leonida:comment:7329693188 --> Imported from [ubiquitarianism/leonida](https://github.com/ProjectLeonida/mandy/pull/2887#issuecomment-7329693188). Originally posted by [fiestorra](https://github.com/fiestorra) on 2026-12-01T23:43:16Z. --- **The red d3d12 (windows-latest) was not this change: it was crash::tests::memory_at_names_what, in crates/leonida-loader, which this branch does not touch.** ` ---- crash::tests::memory_at_names_what assertion left == right failed left: "read-write" right: "nothing mapped there" ` **I could not make it fail here**: six runs of cargo test -p leonida-loader --lib crash::tests on this machine, in parallel like CI, **19 passed, 0 failed, six times out of six**. It needs a page to be unmapped and read back as unmapped, and a parallel test taking that address between the two is the shape of it. **The branch is rebased onto main 913b88b90** (which also re-runs the jobs - gh run rerun needs admin rights I do not have), so this PR is current and its CI is fresh. **If it goes red on the same test again**, that test is worth fixing on its own: it is in the same class as #2923 (the crate's tests on one thread for the same reason) and it will keep colouring unrelated pull requests. **AI-assisted:** yes - DeepSeek v4.1 (flash). Written with an AI assistant.
andrew-ai commented 2026-12-02 00:02:23 +00:00 (Migrated from github.com)

Imported from ubiquitarianism/leonida. Originally posted by andrew-ai on 2026-12-02T00:02:23Z.


Ran a_loaded_pipeline_keeps_its_places_or_loses_them at 3be77fdeb on Windows, RTX 5070 / NVIDIA 616.92, with the diagnostics build and --ignored --nocapture. One test passed. It reported “gives back” and read [22, 20, 21, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12]. This exercises the other accepted result from the RTX 4090 / 621.24 report and matches the earlier sampler-table readback on this machine (#2996). Codex-assisted.

<!-- greyfinch-sync:ubiquitarianism/leonida:comment:7330066631 --> Imported from [ubiquitarianism/leonida](https://github.com/ProjectLeonida/mandy/pull/2887#issuecomment-7330066631). Originally posted by [andrew-ai](https://github.com/andrew-ai) on 2026-12-02T00:02:23Z. --- Ran a_loaded_pipeline_keeps_its_places_or_loses_them at 3be77fdeb on Windows, RTX 5070 / NVIDIA 616.92, with the diagnostics build and --ignored --nocapture. One test passed. It reported “gives back” and read [22, 20, 21, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12]. This exercises the other accepted result from the RTX 4090 / 621.24 report and matches the earlier sampler-table readback on this machine (#2996). Codex-assisted.
MoonEyes commented 2026-12-02 12:30:07 +00:00 (Migrated from github.com)

Imported from ubiquitarianism/leonida. Originally posted by MoonEyes on 2026-12-02T12:30:07Z.


This pull request touches the render path, so it needs an in-game run before it can be merged: unit tests and CI do not catch rendering regressions (a device loss after an earlier merge is why this gate exists).

Could you, or anyone with a working setup, post a run report on the current head merged onto current main:

  • the head SHA and the main SHA it was merged onto;
  • GPU, driver and OS;
  • at least 300 s in the world after loading;
  • device lost / crashes (count), and rendered fps (median) if you have them;
  • the same run on main alone for comparison, if you can.

Please do not attach logs or screenshots that show game content. If a run on this exact head is already posted, a link to it in a reply is enough.

AI-assisted (Claude Code).

<!-- greyfinch-sync:ubiquitarianism/leonida:comment:7345434711 --> Imported from [ubiquitarianism/leonida](https://github.com/ProjectLeonida/mandy/pull/2887#issuecomment-7345434711). Originally posted by [MoonEyes](https://github.com/MoonEyes) on 2026-12-02T12:30:07Z. --- This pull request touches the render path, so it needs an in-game run before it can be merged: unit tests and CI do not catch rendering regressions (a device loss after an earlier merge is why this gate exists). Could you, or anyone with a working setup, post a run report on the **current head** merged onto current `main`: - the head SHA and the `main` SHA it was merged onto; - GPU, driver and OS; - at least 300 s in the world after loading; - device lost / crashes (count), and rendered fps (median) if you have them; - the same run on `main` alone for comparison, if you can. Please do not attach logs or screenshots that show game content. If a run on this exact head is already posted, a link to it in a reply is enough. AI-assisted (Claude Code).
MoonEyes commented 2026-12-02 15:53:33 +00:00 (Migrated from github.com)

Imported from ubiquitarianism/leonida. Originally posted by MoonEyes on 2026-12-02T15:53:33Z.


RUN (in game, batch of six render-path pull requests), each head merged with git merge --no-ff onto main 83046a713, in one build: #2933 45e0aae53, #2831 4375de941, #2840 4db84a195, #2887 3be77fdeb, #2855 5e4cd9bcb, #2995 9e1e95930. RTX 4060 8 GB, driver 610.88, Windows 11. Series S, -Resolution 1080, frame generation 2x, 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.7, mean 17.0
Rendered fps, last 120 s median 16.9

For reference, the same machine and route rendered 13.3 to 15.2 fps today on main with single pull requests and 14.9 with the first batch; no compile ran beside the game this time. 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. If one of these pull requests changes its head, this run no longer covers it.

Limits: one run; free system memory was low (median 1.3 GB); arrival in the world was driven by keys and not checked on pictures.

AI-assisted (Claude Code).

<!-- greyfinch-sync:ubiquitarianism/leonida:comment:7351100502 --> Imported from [ubiquitarianism/leonida](https://github.com/ProjectLeonida/mandy/pull/2887#issuecomment-7351100502). Originally posted by [MoonEyes](https://github.com/MoonEyes) on 2026-12-02T15:53:33Z. --- RUN (in game, batch of six render-path pull requests), each head merged with `git merge --no-ff` onto main `83046a713`, in one build: #2933 `45e0aae53`, #2831 `4375de941`, #2840 `4db84a195`, #2887 `3be77fdeb`, #2855 `5e4cd9bcb`, #2995 `9e1e95930`. RTX 4060 8 GB, driver 610.88, Windows 11. Series S, `-Resolution 1080`, frame generation 2x, 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.7, mean 17.0 | | Rendered fps, last 120 s | median 16.9 | For reference, the same machine and route rendered 13.3 to 15.2 fps today on main with single pull requests and 14.9 with the first batch; no compile ran beside the game this time. 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. If one of these pull requests changes its head, this run no longer covers it. Limits: one run; free system memory was low (median 1.3 GB); arrival in the world was driven by keys and not checked on pictures. AI-assisted (Claude Code).
MoonEyes commented 2026-12-02 18:12:45 +00:00 (Migrated from github.com)

Imported from ubiquitarianism/leonida. Originally posted by MoonEyes on 2026-12-02T18:12:45Z.


Reviewed #2887 (code review only, not built here: Windows-only, needs an NVIDIA card). A test-only measurement probe; heavily verified on real cards, and in-game PASS at this head.

Head 3be77fdeb5
Merge with main 45dc41f95c clean (git merge-tree); merge base 913b88b905, 313 commits behind
Switches registry on the merge exit 0
Evidence (this head, or the earlier 9dfe9b7af) merzleckeier (Wine, RTX 40), Christopher-Sundeby (RTX 5090 / 621.40), NetZlash (RTX 4070 SUPER), andrew-ai (RTX 5070 / 616.92), MoonEyes in-game PASS (2 December 15:53)

Review of d3d12/crates/leonida-gpu/src/pipeline/places/tests.rs (+47, test only)

  • a_loaded_pipeline_keeps_its_places_or_loses_them is #[ignore]d and runs in child processes like the other places tests. It accepts exactly two answers ("kept": places 0-15 unchanged, or "gave back": the 616.64 model's [22, 20, 21] then 0..13) and prints which one the driver gave. Anything else fails with both expectations in the message. That is the right shape for a test whose purpose is to record driver behaviour across versions.
  • Its doc comment says plainly what it does not test (Places::check, and the LEONIDA_LIBRARY_STATIC_SAMPLERS=1 plain path).
  • Limitation, not a defect: it returns early when no device is made or the card is not NVIDIA, so it can pass while testing nothing. fiestorra's finding on #2919 (tests made on the integrated adapter by D3D12CreateDevice(None)) applies here too; the printed vendor line is how a runner can tell.
  • Process: no claim ID and no GPUs tested: line in the description; the AI line names no model.

Verdict: ready (add the claim ID).

AI-assisted: Claude Opus 5.5 (Claude Code), review only.

AI-assisted verification: Claude Opus (Claude Code), separate agent per batch.


Generated by Claude Code

<!-- greyfinch-sync:ubiquitarianism/leonida:comment:7354133155 --> Imported from [ubiquitarianism/leonida](https://github.com/ProjectLeonida/mandy/pull/2887#issuecomment-7354133155). Originally posted by [MoonEyes](https://github.com/MoonEyes) on 2026-12-02T18:12:45Z. --- **Reviewed #2887 (code review only, not built here: Windows-only, needs an NVIDIA card). A test-only measurement probe; heavily verified on real cards, and in-game PASS at this head.** | | | |---|---| | Head | `3be77fdeb5` | | Merge with `main` `45dc41f95c` | clean (`git merge-tree`); merge base `913b88b905`, 313 commits behind | | Switches registry on the merge | exit 0 | | Evidence (this head, or the earlier `9dfe9b7af`) | merzleckeier (Wine, RTX 40), Christopher-Sundeby (RTX 5090 / 621.40), NetZlash (RTX 4070 SUPER), andrew-ai (RTX 5070 / 616.92), MoonEyes in-game PASS (2 December 15:53) | **Review of `d3d12/crates/leonida-gpu/src/pipeline/places/tests.rs` (+47, test only)** - `a_loaded_pipeline_keeps_its_places_or_loses_them` is `#[ignore]`d and runs in child processes like the other `places` tests. It accepts exactly two answers ("kept": places 0-15 unchanged, or "gave back": the 616.64 model's `[22, 20, 21]` then `0..13`) and prints which one the driver gave. Anything else fails with both expectations in the message. That is the right shape for a test whose purpose is to record driver behaviour across versions. - Its doc comment says plainly what it does not test (`Places::check`, and the `LEONIDA_LIBRARY_STATIC_SAMPLERS=1` plain path). - Limitation, not a defect: it returns early when no device is made or the card is not NVIDIA, so it can pass while testing nothing. fiestorra's finding on #2919 (tests made on the integrated adapter by `D3D12CreateDevice(None)`) applies here too; the printed vendor line is how a runner can tell. - Process: no claim ID and no `GPUs tested:` line in the description; the AI line names no model. **Verdict: ready** (add the claim ID). AI-assisted: Claude Opus 5.5 (Claude Code), review only. AI-assisted verification: Claude Opus (Claude Code), separate agent per batch. --- _Generated by [Claude Code](https://claude.ai/code)_
fiestorra commented 2026-12-02 18:23:41 +00:00 (Migrated from github.com)

Imported from ubiquitarianism/leonida. Originally posted by fiestorra on 2026-12-02T18:23:41Z.


Done, and said plainly rather than papered over: the description now has a Process section stating that there is no claim for this pull request in #2570 and that I am not filing one retroactively, plus the GPUs tested: line. Thanks for reading it closely.

<!-- greyfinch-sync:ubiquitarianism/leonida:comment:7354506382 --> Imported from [ubiquitarianism/leonida](https://github.com/ProjectLeonida/mandy/pull/2887#issuecomment-7354506382). Originally posted by [fiestorra](https://github.com/fiestorra) on 2026-12-02T18:23:41Z. --- Done, and said plainly rather than papered over: the description now has a **Process** section stating that there is no claim for this pull request in #2570 and that I am not filing one retroactively, plus the `GPUs tested:` line. Thanks for reading it closely.
This pull request cannot be merged automatically due to conflicts.
Merge manually to resolve the conflicts.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin 'upstream-pr/2887:upstream-pr/2887'
git switch 'upstream-pr/2887'

Merge

Merge the changes and update on Forgejo.

Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.

git switch 'main'
git merge --no-ff 'upstream-pr/2887'
git switch 'upstream-pr/2887'
git rebase 'main'
git switch 'main'
git merge --ff-only 'upstream-pr/2887'
git switch 'upstream-pr/2887'
git rebase 'main'
git switch 'main'
git merge --no-ff 'upstream-pr/2887'
git switch 'main'
git merge --squash 'upstream-pr/2887'
git switch 'main'
git merge --ff-only 'upstream-pr/2887'
git switch 'main'
git merge 'upstream-pr/2887'
git push origin 'main'
Sign in to join this conversation.
No reviewers
No labels
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.

Reference
ProjectLeonida/mandy!2887
No description provided.