GPU: show the frame rate and frame time in the picture (VICTORY_FPS=0 turns it off) #3697

Open
rpmaster2 wants to merge 5 commits from upstream-pr/3697 into main
rpmaster2 commented 2026-11-28 08:42:01 +00:00 (Migrated from github.com)

Imported from Marvisak/VIctory. Originally posted by rpmaster2 on 2026-11-28T08:42:01Z.


# GPU: show the frame rate and frame time in the picture (VICTORY_FPS=0 turns it off)

The window caption already carries the frame rate, but a borderless or full-screen window has none, and in a title that runs at one or two frames a second the caption is often not visible at all. This writes the numbers in the top left corner of the back buffer as cleared rectangles: no shader, no texture, no font, no extra draw.

Provenance — this is not my code

The readout is taken verbatim from Belobug/VIctory-Belobug-AMD, commit 50a9fa4 "Show the frame rate and frame time in the picture" (author beloooo, Co-Authored-By: Claude Fable 5.2 <[email protected]>), under GPL-3.0-or-later, the same licence as here. That repository has since been deleted from GitHub; the commit hash and its message are quoted above so the origin stays checkable. crates/victory-gpu/src/readout.rs is byte-identical to theirs.

What I changed to make it fit this tree:

  • crates/victory-gpu/src/readout.rs: new file, copied unchanged (92 lines);
  • crates/victory-gpu/src/lib.rs: mod readout;
  • crates/victory-gpu/src/host.rs: the rtv field on Presenter and its one-view heap, Meter.shown (the last second's numbers), Presenter::readout, and the call in the single-plane present path with the two resource transitions around it (COPY_DEST -> RENDER_TARGET and back). Their tree has the same shape, so the adaptation is small, but the arithmetic of the digits is entirely theirs.

The second commit, f8c1229 "GPU: keep the frame readout optional", is not mine either: it was written by andrewpozdnakov7-jpg (Co-Authored-By preserved) after reviewing the first one. It makes the heap optional and records the transitions only when the readout actually draws, so VICTORY_FPS=0 costs nothing, and it guards mod readout with #[cfg(windows)]. Their change is included here as-is so it does not have to be carried separately.

Behaviour

  • VICTORY_FPS unset or any value but 0: the readout is drawn, updated once a second from the same Meter that writes the caption and the log line.
  • VICTORY_FPS=0: nothing is recorded and nothing is drawn — no heap, no barriers, no clears (the second commit).
  • Dot size scales with the height (height / 216, at least 2 px), so it stays readable at 1080p and 4K; the background rectangle is only drawn if it fits inside the picture, so a tiny window cannot fault.
  • One render target view for the swap chain; the back buffer is transitioned to RENDER_TARGET for the two ClearRenderTargetView calls and back (or already is, on the composited path), so the present path is unchanged.
  • Both present paths are covered: the single-plane copy, and the PresentX compositor the --console series-s profile uses to put a 1080p scene plane and a 4K interface plane together. On the composited path the back buffer is already a render target when the planes are drawn, so the readout is drawn there with no transitions (dc36368).

One correction, for the record

While testing on my card (RX 9070 XT, RDNA4) I first reported that this hook made the picture go black, with only the digits visible. That was wrong. I dumped frames with VICTORY_CAPTURE and measured them: the title itself presents black frames for roughly its first hundred frames while its pipelines and streams warm up — frames 1–64 measured at exactly zero brightness, frame 128 at 13 % of the picture, 256 at 31 %, 512 at 39 %, 1024 at 48 %. Subtitles are drawn over that black, which makes it look like a broken composite. On the same save, main reaches the first visible frame in about ninety seconds and a run with the readout takes about twice as long, because the frames are slower; that is the whole of the difference I saw, not the readout.

So: the readout does not touch the picture beyond its own corner, and the earlier black-screen claim in my comments on this PR is withdrawn.

How it was checked

  • cargo build --locked --profile diag -p victory --features diagnostics on Windows 11 26100, Rust 1.98.1;
  • cargo test --locked -p victory-gpu --lib readout: 1 passed, 0 failed, 232 filtered out (the file's own a_row_of_dots_is_one_rectangle);
  • a five-minute run on the RX 9070 XT with the readout on, --console series-x: the numbers appear top left, match the caption and the log line, and the picture is intact; VICTORY_FPS=0 removes them;
  • the same on --console series-s, which presents through the compositor: no numbers before dc36368, numbers after it, picture unchanged;
  • frame dumps with and without the switch, same binary, same save and same scripted keys, five minutes each (--console series-s, where at that point the readout was not drawing yet): both sets black at frames 64 and 128, then 33/132/111 against 33/147/74 at 256/512/1024 — the spread is scene timing;
  • the cost of the readout while it actually draws is being measured now (same binary, VICTORY_FPS=0 against VICTORY_FPS=1, five minutes each, frame counts and milliseconds), and I will post it here rather than claim the readout is free.

AI-assisted: written by DeepSeek (OpenCode harness) using the original commits' code and my run logs; no game files or paths.

<!-- greyfinch-sync:Marvisak/VIctory:issue:5538402774 --> Imported from [Marvisak/VIctory](https://github.com/Marvisak/VIctory/pull/3697). Originally posted by [rpmaster2](https://github.com/rpmaster2) on 2026-11-28T08:42:01Z. --- # GPU: show the frame rate and frame time in the picture (`VICTORY_FPS=0` turns it off) The window caption already carries the frame rate, but a borderless or full-screen window has none, and in a title that runs at one or two frames a second the caption is often not visible at all. This writes the numbers in the top left corner of the back buffer as cleared rectangles: no shader, no texture, no font, no extra draw. ## Provenance — this is not my code The readout is taken **verbatim** from `Belobug/VIctory-Belobug-AMD`, commit `50a9fa4` "Show the frame rate and frame time in the picture" (author **beloooo**, `Co-Authored-By: Claude Fable 5.2 <[email protected]>`), under GPL-3.0-or-later, the same licence as here. That repository has since been deleted from GitHub; the commit hash and its message are quoted above so the origin stays checkable. `crates/victory-gpu/src/readout.rs` is byte-identical to theirs. What I changed to make it fit this tree: - `crates/victory-gpu/src/readout.rs`: new file, copied unchanged (92 lines); - `crates/victory-gpu/src/lib.rs`: `mod readout;` - `crates/victory-gpu/src/host.rs`: the `rtv` field on `Presenter` and its one-view heap, `Meter.shown` (the last second's numbers), `Presenter::readout`, and the call in the single-plane present path with the two resource transitions around it (`COPY_DEST -> RENDER_TARGET` and back). Their tree has the same shape, so the adaptation is small, but the arithmetic of the digits is entirely theirs. The second commit, `f8c1229` "GPU: keep the frame readout optional", is **not mine either**: it was written by **andrewpozdnakov7-jpg** (`Co-Authored-By` preserved) after reviewing the first one. It makes the heap optional and records the transitions only when the readout actually draws, so `VICTORY_FPS=0` costs nothing, and it guards `mod readout` with `#[cfg(windows)]`. Their change is included here as-is so it does not have to be carried separately. ## Behaviour - `VICTORY_FPS` unset or any value but `0`: the readout is drawn, updated once a second from the same `Meter` that writes the caption and the log line. - `VICTORY_FPS=0`: nothing is recorded and nothing is drawn — no heap, no barriers, no clears (the second commit). - Dot size scales with the height (`height / 216`, at least 2 px), so it stays readable at 1080p and 4K; the background rectangle is only drawn if it fits inside the picture, so a tiny window cannot fault. - One render target view for the swap chain; the back buffer is transitioned to `RENDER_TARGET` for the two `ClearRenderTargetView` calls and back (or already is, on the composited path), so the present path is unchanged. - Both present paths are covered: the single-plane copy, and the `PresentX` compositor the `--console series-s` profile uses to put a 1080p scene plane and a 4K interface plane together. On the composited path the back buffer is already a render target when the planes are drawn, so the readout is drawn there with no transitions (`dc36368`). ## One correction, for the record While testing on my card (RX 9070 XT, RDNA4) I first reported that this hook made the picture go black, with only the digits visible. That was wrong. I dumped frames with `VICTORY_CAPTURE` and measured them: **the title itself presents black frames for roughly its first hundred frames** while its pipelines and streams warm up — frames 1–64 measured at exactly zero brightness, frame 128 at 13 % of the picture, 256 at 31 %, 512 at 39 %, 1024 at 48 %. Subtitles are drawn over that black, which makes it look like a broken composite. On the same save, `main` reaches the first visible frame in about ninety seconds and a run with the readout takes about twice as long, because the frames are slower; that is the whole of the difference I saw, not the readout. So: the readout does not touch the picture beyond its own corner, and the earlier black-screen claim in my comments on this PR is withdrawn. ## How it was checked - `cargo build --locked --profile diag -p victory --features diagnostics` on Windows 11 26100, Rust 1.98.1; - `cargo test --locked -p victory-gpu --lib readout`: 1 passed, 0 failed, 232 filtered out (the file's own `a_row_of_dots_is_one_rectangle`); - a five-minute run on the RX 9070 XT with the readout on, `--console series-x`: the numbers appear top left, match the caption and the log line, and the picture is intact; `VICTORY_FPS=0` removes them; - the same on `--console series-s`, which presents through the compositor: no numbers before `dc36368`, numbers after it, picture unchanged; - frame dumps with and without the switch, same binary, same save and same scripted keys, five minutes each (`--console series-s`, where at that point the readout was not drawing yet): both sets black at frames 64 and 128, then 33/132/111 against 33/147/74 at 256/512/1024 — the spread is scene timing; - the cost of the readout while it actually draws is being measured now (same binary, `VICTORY_FPS=0` against `VICTORY_FPS=1`, five minutes each, frame counts and milliseconds), and I will post it here rather than claim the readout is free. AI-assisted: written by DeepSeek (OpenCode harness) using the original commits' code and my run logs; no game files or paths.
andrewpozdnakov7-jpg commented 2026-11-28 09:03:14 +00:00 (Migrated from github.com)

Imported from Marvisak/VIctory. Originally posted by andrewpozdnakov7-jpg on 2026-11-28T09:03:14Z.


I tested the readout on 82607c2 with three generated RGBA8 frames: before the first timing sample, after a sample and at a size too narrow for the text. On WARP the readout colors were correct and the rest of the frame stayed unchanged. With VICTORY_FPS=0, all pixels stayed unchanged, but the presenter still made one readout RTV heap and recorded two readout barriers on every frame.

7eefa83 makes the readout heap optional and records the transitions only when it draws. The same WARP check with the debug layer gives zero heap allocations and zero readout barriers with the switch off, and one pair of barriers across all three frames with the switch on. The pixels match the original in both modes. The existing glyph test, compositor fallback test, both GPU Clippy configurations and asset policy passed.

The follow-up also guards mod readout with #[cfg(windows)], matching the target-specific Windows dependency. If the optional heap cannot be created, presentation can continue without the readout.

@rpmaster2, could you review this follow-up for inclusion? Please retain the Git author if you cherry-pick or rebase it, or add Co-authored-by: andrewpozdnakov7-jpg <[email protected]> if folding it into another commit.

AI-assisted with OpenAI Codex.

<!-- greyfinch-sync:Marvisak/VIctory:comment:7236981650 --> Imported from [Marvisak/VIctory](https://github.com/Marvisak/VIctory/pull/3697#issuecomment-7236981650). Originally posted by [andrewpozdnakov7-jpg](https://github.com/andrewpozdnakov7-jpg) on 2026-11-28T09:03:14Z. --- I tested the readout on `82607c2` with three generated RGBA8 frames: before the first timing sample, after a sample and at a size too narrow for the text. On WARP the readout colors were correct and the rest of the frame stayed unchanged. With `VICTORY_FPS=0`, all pixels stayed unchanged, but the presenter still made one readout RTV heap and recorded two readout barriers on every frame. [`7eefa83`](https://github.com/andrewpozdnakov7-jpg/VIctory/commit/7eefa836dbe4fad500989649909745a9aa9bcefc) makes the readout heap optional and records the transitions only when it draws. The same WARP check with the debug layer gives zero heap allocations and zero readout barriers with the switch off, and one pair of barriers across all three frames with the switch on. The pixels match the original in both modes. The existing glyph test, compositor fallback test, both GPU Clippy configurations and asset policy passed. The follow-up also guards `mod readout` with `#[cfg(windows)]`, matching the target-specific Windows dependency. If the optional heap cannot be created, presentation can continue without the readout. @rpmaster2, could you review this follow-up for inclusion? Please retain the Git author if you cherry-pick or rebase it, or add `Co-authored-by: andrewpozdnakov7-jpg <[email protected]>` if folding it into another commit. AI-assisted with OpenAI Codex.
rpmaster2 commented 2026-11-28 09:05:49 +00:00 (Migrated from github.com)

Imported from Marvisak/VIctory. Originally posted by rpmaster2 on 2026-11-28T09:05:49Z.


Thanks — the switch-off gap you found is real, and I would like your follow-up in this PR with your authorship kept (I will cherry-pick 7eefa83 rather than retype it, or add the Co-authored-by line if it needs adapting).

One thing I have to report, because it changes where the readout draws: on RDNA4 the drawing path itself takes the picture away, and your WARP check cannot see it. RX 9070 XT, Adrenalin 26.11.2 (32.0.32029.2010), Windows 11 26100, upstream main 63bcca4 plus this PR's hook:

  • VICTORY_FPS=0 with the hook fully skipped: picture normal.
  • VICTORY_FPS on, digits on the back buffer (the commit you tested): frame black, only the digits visible, ~0.6 fps.
  • Same, with the back buffer left COPY_DEST between the clears and the PRESENT transition: same black frame.
  • Drawing the digits on the scene texture before it is copied to the swap chain (nothing on the back buffer at all): still black, digits visible.

So it is not the swap chain's discarded content and not the extra transitions: on this driver a sub-rect ClearRenderTargetView on the resource that ends up presented leaves the rest of it black. Everything else in the present path is byte-for-byte main. The same code inside the fork's tree does not do this on the same card, so the difference is somewhere in how that tree presents, not in the digits.

I am therefore reworking the hook to draw the digits into a small texture of their own (a full clear to black plus the glyph rects, both safe on a texture we own) and copy that texture into the frame's corner with CopyTextureRegion, leaving the presented resource in COPY_DEST with no clears and no RENDER_TARGET transition. When that is in, I will post the results and the exact diff. If you have a machine with a discrete AMD card, running your three-frame WARP check on real hardware, with and without the switch, would be a good independent check of the fix — WARP cannot reproduce this class of failure.

AI-assisted: written by DeepSeek (OpenCode harness) from my run logs; no game files or paths.

<!-- greyfinch-sync:Marvisak/VIctory:comment:7237010892 --> Imported from [Marvisak/VIctory](https://github.com/Marvisak/VIctory/pull/3697#issuecomment-7237010892). Originally posted by [rpmaster2](https://github.com/rpmaster2) on 2026-11-28T09:05:49Z. --- Thanks — the switch-off gap you found is real, and I would like your follow-up in this PR with your authorship kept (I will cherry-pick `7eefa83` rather than retype it, or add the `Co-authored-by` line if it needs adapting). One thing I have to report, because it changes where the readout draws: **on RDNA4 the drawing path itself takes the picture away, and your WARP check cannot see it.** RX 9070 XT, Adrenalin 26.11.2 (32.0.32029.2010), Windows 11 26100, upstream `main` `63bcca4` plus this PR's hook: - `VICTORY_FPS=0` with the hook fully skipped: picture normal. - `VICTORY_FPS` on, digits on the back buffer (the commit you tested): **frame black, only the digits visible**, ~0.6 fps. - Same, with the back buffer left `COPY_DEST` between the clears and the `PRESENT` transition: same black frame. - Drawing the digits on the **scene texture** before it is copied to the swap chain (nothing on the back buffer at all): still black, digits visible. So it is not the swap chain's discarded content and not the extra transitions: on this driver a sub-rect `ClearRenderTargetView` on the resource that ends up presented leaves the rest of it black. Everything else in the present path is byte-for-byte `main`. The same code inside the fork's tree does not do this on the same card, so the difference is somewhere in how that tree presents, not in the digits. I am therefore reworking the hook to draw the digits into a small texture of their own (a full clear to black plus the glyph rects, both safe on a texture we own) and copy that texture into the frame's corner with `CopyTextureRegion`, leaving the presented resource in `COPY_DEST` with no clears and no `RENDER_TARGET` transition. When that is in, I will post the results and the exact diff. If you have a machine with a discrete AMD card, running your three-frame WARP check on real hardware, with and without the switch, would be a good independent check of the fix — WARP cannot reproduce this class of failure. AI-assisted: written by DeepSeek (OpenCode harness) from my run logs; no game files or paths.
andrewpozdnakov7-jpg commented 2026-11-28 09:10:24 +00:00 (Migrated from github.com)

Imported from Marvisak/VIctory. Originally posted by andrewpozdnakov7-jpg on 2026-11-28T09:10:24Z.


Thanks for the RDNA4 results. I checked the available adapters and don't have a discrete AMD card on this machine. Once the revised commit is up, I can rerun the WARP pixel checks for the copy-to-corner path with the readout on and off. The RX 9070 XT check will need your hardware or another AMD tester.

AI-assisted with OpenAI Codex.

<!-- greyfinch-sync:Marvisak/VIctory:comment:7237063767 --> Imported from [Marvisak/VIctory](https://github.com/Marvisak/VIctory/pull/3697#issuecomment-7237063767). Originally posted by [andrewpozdnakov7-jpg](https://github.com/andrewpozdnakov7-jpg) on 2026-11-28T09:10:24Z. --- Thanks for the RDNA4 results. I checked the available adapters and don't have a discrete AMD card on this machine. Once the revised commit is up, I can rerun the WARP pixel checks for the copy-to-corner path with the readout on and off. The RX 9070 XT check will need your hardware or another AMD tester. AI-assisted with OpenAI Codex.
andrewpozdnakov7-jpg commented 2026-11-28 09:50:03 +00:00 (Migrated from github.com)

Imported from Marvisak/VIctory. Originally posted by andrewpozdnakov7-jpg on 2026-11-28T09:50:03Z.


I reproduced the Clippy failure at f85c696. The local change that places the safety comment immediately above the unsafe block is byte-identical to your current dc36368 tree. The Windows CI run at that head passed. Both local Clippy configurations and asset policy also passed.

I extended the synthetic WARP check to a 320×128 single-plane red frame and a two-plane red/half-blue blend. The fixture reads the final back-buffer pixels. For the single-plane case I placed the test-only readback after the overlay so it includes the digits.

  • VICTORY_FPS=0: all pixels matched the expected background in both paths, with zero readout transitions.
  • VICTORY_FPS=1: checked the glyph and backdrop colors, and every pixel outside the readout matched the expected background. The single-plane path recorded two readout transitions. The composited path recorded zero.

All four combinations of the FPS switch and D3D12 debug switch passed on app-local WARP 1.0.22 and Agility 1.620.2. The RX 9070 XT evidence remains the author's hardware run.

If reusing this fixture work, please retain Git authorship or include Co-authored-by: andrewpozdnakov7-jpg <[email protected]>.

AI-assisted with OpenAI Codex.

<!-- greyfinch-sync:Marvisak/VIctory:comment:7237496531 --> Imported from [Marvisak/VIctory](https://github.com/Marvisak/VIctory/pull/3697#issuecomment-7237496531). Originally posted by [andrewpozdnakov7-jpg](https://github.com/andrewpozdnakov7-jpg) on 2026-11-28T09:50:03Z. --- I reproduced the Clippy failure at `f85c696`. The local change that places the safety comment immediately above the unsafe block is byte-identical to your current `dc36368` tree. The [Windows CI run at that head](https://github.com/Marvisak/VIctory/actions/runs/46132063677/job/140939185746) passed. Both local Clippy configurations and asset policy also passed. I extended the synthetic WARP check to a 320×128 single-plane red frame and a two-plane red/half-blue blend. The fixture reads the final back-buffer pixels. For the single-plane case I placed the test-only readback after the overlay so it includes the digits. - `VICTORY_FPS=0`: all pixels matched the expected background in both paths, with zero readout transitions. - `VICTORY_FPS=1`: checked the glyph and backdrop colors, and every pixel outside the readout matched the expected background. The single-plane path recorded two readout transitions. The composited path recorded zero. All four combinations of the FPS switch and D3D12 debug switch passed on app-local WARP 1.0.22 and Agility 1.620.2. The RX 9070 XT evidence remains the author's hardware run. If reusing this fixture work, please retain Git authorship or include `Co-authored-by: andrewpozdnakov7-jpg <[email protected]>`. AI-assisted with OpenAI Codex.
rpmaster2 commented 2026-11-28 09:51:21 +00:00 (Migrated from github.com)

Imported from Marvisak/VIctory. Originally posted by rpmaster2 on 2026-11-28T09:51:21Z.


Your transition counts match what the hardware shows, including the zero on the composited path — after f85c696 the readout runs after the planes are composed, where the back buffer is already a render target, so nothing is transitioned there. Thanks for extending the fixture to both paths; that is exactly the combination I could not check on WARP.

I have to withdraw my own claim above. I wrote that the RDNA4 frame went black when the readout drew, and that a sub-rect ClearRenderTargetView on the presented resource was the cause. That was wrong, and the fix I announced (a small texture copied into the corner) never worked: it drew nothing, and after the ALLOW_RENDER_TARGET mistake was corrected it crashed the title reproducibly inside D3D12Core.dll (0xC0000094, 2 of 2 runs, about half a second after the first copy), so that whole approach is discarded.

The black frames were the title's own. I captured frames with VICTORY_CAPTURE and measured them, in one and the same run, with the readout drawing:

frame main (63bcca4) this branch
64 0.0 0.0
128 0.0 33.4
256 33.4 79.5
512 118.6 99.1
1024 32.9 121.7

Mean brightness, 0–255. The title presents black frames for roughly its first hundred frames while its pipelines and streams warm up, and subtitles are drawn over that black — which reads like a broken composite. main also returns to a near-black frame at 1024 on the same save. What misled me was timing: main is faster, so it passes that phase sooner.

Two things still open on my side, both being measured on the card now: the cost of the readout while it actually draws (same binary, VICTORY_FPS=0 against VICTORY_FPS=1, five minutes each on --console series-s), and a cold-start comparison after warming the pipeline library offline. The numbers go in this thread either way.

AI-assisted: written by DeepSeek (OpenCode harness) from my run logs and frame dumps; no game files or paths.

<!-- greyfinch-sync:Marvisak/VIctory:comment:7237510730 --> Imported from [Marvisak/VIctory](https://github.com/Marvisak/VIctory/pull/3697#issuecomment-7237510730). Originally posted by [rpmaster2](https://github.com/rpmaster2) on 2026-11-28T09:51:21Z. --- Your transition counts match what the hardware shows, including the zero on the composited path — after `f85c696` the readout runs after the planes are composed, where the back buffer is already a render target, so nothing is transitioned there. Thanks for extending the fixture to both paths; that is exactly the combination I could not check on WARP. **I have to withdraw my own claim above.** I wrote that the RDNA4 frame went black when the readout drew, and that a sub-rect `ClearRenderTargetView` on the presented resource was the cause. That was wrong, and the fix I announced (a small texture copied into the corner) never worked: it drew nothing, and after the `ALLOW_RENDER_TARGET` mistake was corrected it crashed the title reproducibly inside `D3D12Core.dll` (`0xC0000094`, 2 of 2 runs, about half a second after the first copy), so that whole approach is discarded. The black frames were the title's own. I captured frames with `VICTORY_CAPTURE` and measured them, in one and the same run, with the readout drawing: | frame | `main` (`63bcca4`) | this branch | |---|---|---| | 64 | 0.0 | 0.0 | | 128 | 0.0 | 33.4 | | 256 | 33.4 | 79.5 | | 512 | 118.6 | 99.1 | | 1024 | 32.9 | 121.7 | Mean brightness, 0–255. The title presents black frames for roughly its first hundred frames while its pipelines and streams warm up, and subtitles are drawn over that black — which reads like a broken composite. `main` also returns to a near-black frame at 1024 on the same save. What misled me was timing: `main` is faster, so it passes that phase sooner. Two things still open on my side, both being measured on the card now: the cost of the readout while it actually draws (same binary, `VICTORY_FPS=0` against `VICTORY_FPS=1`, five minutes each on `--console series-s`), and a cold-start comparison after warming the pipeline library offline. The numbers go in this thread either way. AI-assisted: written by DeepSeek (OpenCode harness) from my run logs and frame dumps; no game files or paths.
rpmaster2 commented 2026-11-28 09:55:42 +00:00 (Migrated from github.com)

Imported from Marvisak/VIctory. Originally posted by rpmaster2 on 2026-11-28T09:55:42Z.


The cost measurement is in, and it does not show a cost — with a caveat I would rather state than hide.

Same binary (dc36368), same restored save, same scripted keys, two runs of four minutes on --console series-s, VICTORY_CAPTURE in both:

switch frames logged black frames mean frame time last samples
VICTORY_FPS=0 42 11 1,188 ms 1.5 fps / 657 ms
VICTORY_FPS=1 41 8 785 ms 3.9 fps / 257 ms

The run with the readout on came out faster, which is not the readout's doing: by then it had reached a lighter part of the scene. So what this pair really says is "no difference detectable", not "the readout is free". The frame dumps say the same thing in pictures: black at frame 64 in both, then 33.4/79.5/99.1/121.7 against 0.6/33.7/147.5/65.5 at 128/256/512/1024 — diverging in both directions as the two runs stream at different moments.

Why I believe the cost really is negligible, by construction rather than by this measurement: the digits are redrawn only when the numbers change, once a second, and that is two ClearRenderTargetView calls on rectangles of about 1000×90 pixels plus two barriers — on a frame that currently takes 250–1,200 ms. Everything else is the same command list as before. If someone wants a tighter number, the honest way is a frame-by-frame comparison at matched frame numbers, and I can run that on this card; I did not want to present four minutes of scene drift as evidence either way.

Separately: the black frames at the start of every run here are the title's own warm-up, not this PR (frames 1–64 measured at zero brightness, 128 at 13 %, 256 at 31 %, 512 at 39 %, 1024 at 48 % in one run). I am now warming the pipeline library offline with victory translate --cache --pipelines, which is the thing that actually shortens that phase, and I will post before/after numbers.

AI-assisted: written by DeepSeek (OpenCode harness) from my run logs and frame dumps; no game files or paths.

<!-- greyfinch-sync:Marvisak/VIctory:comment:7237557070 --> Imported from [Marvisak/VIctory](https://github.com/Marvisak/VIctory/pull/3697#issuecomment-7237557070). Originally posted by [rpmaster2](https://github.com/rpmaster2) on 2026-11-28T09:55:42Z. --- The cost measurement is in, and it does not show a cost — with a caveat I would rather state than hide. Same binary (`dc36368`), same restored save, same scripted keys, two runs of four minutes on `--console series-s`, `VICTORY_CAPTURE` in both: | switch | frames logged | black frames | mean frame time | last samples | |---|---|---|---|---| | `VICTORY_FPS=0` | 42 | 11 | 1,188 ms | 1.5 fps / 657 ms | | `VICTORY_FPS=1` | 41 | 8 | 785 ms | 3.9 fps / 257 ms | The run with the readout on came out **faster**, which is not the readout's doing: by then it had reached a lighter part of the scene. So what this pair really says is "no difference detectable", not "the readout is free". The frame dumps say the same thing in pictures: black at frame 64 in both, then 33.4/79.5/99.1/121.7 against 0.6/33.7/147.5/65.5 at 128/256/512/1024 — diverging in both directions as the two runs stream at different moments. Why I believe the cost really is negligible, by construction rather than by this measurement: the digits are redrawn only when the numbers change, once a second, and that is two `ClearRenderTargetView` calls on rectangles of about 1000×90 pixels plus two barriers — on a frame that currently takes 250–1,200 ms. Everything else is the same command list as before. If someone wants a tighter number, the honest way is a frame-by-frame comparison at matched frame numbers, and I can run that on this card; I did not want to present four minutes of scene drift as evidence either way. Separately: the black frames at the start of every run here are the title's own warm-up, not this PR (frames 1–64 measured at zero brightness, 128 at 13 %, 256 at 31 %, 512 at 39 %, 1024 at 48 % in one run). I am now warming the pipeline library offline with `victory translate --cache --pipelines`, which is the thing that actually shortens that phase, and I will post before/after numbers. AI-assisted: written by DeepSeek (OpenCode harness) from my run logs and frame dumps; no game files or paths.
andrewpozdnakov7-jpg commented 2026-11-28 09:59:33 +00:00 (Migrated from github.com)

Imported from Marvisak/VIctory. Originally posted by andrewpozdnakov7-jpg on 2026-11-28T09:59:33Z.


One detail about the cost argument on dc36368. Meter::frame updates the sampled FPS and frame time about once a second. Presenter::readout draws that sample again whenever the frame is presented and the overlay fits.

I held the same timing sample for three consecutive frames on each path. On app-local WARP, the test counted six readout clears in three single-plane frames and six in three composited frames, with the glyph and background pixels checked in each frame. With VICTORY_FPS=0, both counts were zero. The result held with the D3D12 debug switch off and on.

Those counts establish how often the work is submitted. Your matched-scene comparison would be the way to measure its cost on the RX 9070 XT.

AI-assisted with OpenAI Codex.

<!-- greyfinch-sync:Marvisak/VIctory:comment:7237597831 --> Imported from [Marvisak/VIctory](https://github.com/Marvisak/VIctory/pull/3697#issuecomment-7237597831). Originally posted by [andrewpozdnakov7-jpg](https://github.com/andrewpozdnakov7-jpg) on 2026-11-28T09:59:33Z. --- One detail about the cost argument on `dc36368`. `Meter::frame` updates the sampled FPS and frame time about once a second. `Presenter::readout` draws that sample again whenever the frame is presented and the overlay fits. I held the same timing sample for three consecutive frames on each path. On app-local WARP, the test counted six readout clears in three single-plane frames and six in three composited frames, with the glyph and background pixels checked in each frame. With `VICTORY_FPS=0`, both counts were zero. The result held with the D3D12 debug switch off and on. Those counts establish how often the work is submitted. Your matched-scene comparison would be the way to measure its cost on the RX 9070 XT. AI-assisted with OpenAI Codex.
andrewpozdnakov7-jpg commented 2026-11-28 10:16:42 +00:00 (Migrated from github.com)

Imported from Marvisak/VIctory. Originally posted by andrewpozdnakov7-jpg on 2026-11-28T10:16:42Z.


I found a diagnostic difference when the readout is enabled on dc36368. The composited path reads the back buffer after drawing the readout. In a generated black 188×64 scene, a probe point landed at (23, 8) on a yellow glyph. The scene was classified as non-black and the capture contained the yellow pixel.

7fbc4e4 moves the composited capture and probe ahead of the readout. On app-local WARP with the debug layer, both switch settings now classify the same scene as black. With the readout on, the diagnostic capture read [0, 0, 0, 255] at that point and a separate final-buffer readback still read [255, 230, 26, 255]. The single-plane control also kept the glyph visible and classified the scene as black.

The composited diagnostics path transitions from copy-source to render-target only when the readout draws, then directly to present. The standard composited path already has the render-target state. Both GPU Clippy configurations and the asset policy passed.

@rpmaster2, could you review the diagnostic ordering? Please retain the Git author if you cherry-pick or rebase the fix, or add Co-authored-by: andrewpozdnakov7-jpg <[email protected]> if folding it into another commit.

AI-assisted with OpenAI Codex.

<!-- greyfinch-sync:Marvisak/VIctory:comment:7237791042 --> Imported from [Marvisak/VIctory](https://github.com/Marvisak/VIctory/pull/3697#issuecomment-7237791042). Originally posted by [andrewpozdnakov7-jpg](https://github.com/andrewpozdnakov7-jpg) on 2026-11-28T10:16:42Z. --- I found a diagnostic difference when the readout is enabled on `dc36368`. The composited path reads the back buffer after drawing the readout. In a generated black 188×64 scene, a probe point landed at `(23, 8)` on a yellow glyph. The scene was classified as non-black and the capture contained the yellow pixel. [`7fbc4e4`](https://github.com/andrewpozdnakov7-jpg/VIctory/commit/7fbc4e46c45a159dcc811aa62e0a4417b83f0451) moves the composited capture and probe ahead of the readout. On app-local WARP with the debug layer, both switch settings now classify the same scene as black. With the readout on, the diagnostic capture read `[0, 0, 0, 255]` at that point and a separate final-buffer readback still read `[255, 230, 26, 255]`. The single-plane control also kept the glyph visible and classified the scene as black. The composited diagnostics path transitions from copy-source to render-target only when the readout draws, then directly to present. The standard composited path already has the render-target state. Both GPU Clippy configurations and the asset policy passed. @rpmaster2, could you review the diagnostic ordering? Please retain the Git author if you cherry-pick or rebase the fix, or add `Co-authored-by: andrewpozdnakov7-jpg <[email protected]>` if folding it into another commit. AI-assisted with OpenAI Codex.
rpmaster2 commented 2026-11-28 10:39:51 +00:00 (Migrated from github.com)

Imported from Marvisak/VIctory. Originally posted by rpmaster2 on 2026-11-28T10:39:51Z.


You are right on both counts, and the first one is my error, not a detail.

On the cost. I wrote that the digits are redrawn only when the numbers change, once a second. They are not: Presenter::readout is called on every presented frame and records both ClearRenderTargetView calls each time, using whatever the last one-second sample says. Your six clears in three frames on each path is what the code does, and my "two clears a second" was wrong. The correct claim is: two clears plus a barrier pair at most, once per presented frame, on a target size of roughly height / 216 × 3 dots of margin plus the text.

That makes my matched-scene measurement weaker than I presented it: with frames at 250–1,200 ms in that pair, two clears are still far below the noise, but I cannot separate them from scene drift, and I should not have implied the drawing frequency was lower than it is. The honest summary of my data is "no difference detectable in four minutes of drifting scene", and the way to get a real number is what you suggest — hold the scene, count frames to a fixed point with the switch off and on, which I can do on this card.

On the diagnostic ordering. Good catch, and it matters beyond the tests: with the readout on, the composited path's capture and probe see the yellow glyph, so a black scene is classified as non-black, and someone debugging a black frame would be told the wrong thing. The capture should describe the title's frame, not our overlay. I will cherry-pick 7fbc4e4 with your authorship and date intact, as before, and confirm the build and both Clippy configurations here; if the composited diagnostics path needs the COPY_SOURCE -> RENDER_TARGET transition only when the readout draws, that is already how the switch-off case behaves and I will check it stays that way with VICTORY_FPS=0.

One thing I would ask: with the capture moved ahead of the readout, is there still a way, in a test, to assert that the glyph reached the final back buffer on the composited path? Your [255, 230, 26, 255] readback does exactly that; if that readback is part of 7fbc4e4, nothing more is needed and I will keep it as is.

AI-assisted: written by DeepSeek (OpenCode harness) from my run logs; no game files or paths.

<!-- greyfinch-sync:Marvisak/VIctory:comment:7238040974 --> Imported from [Marvisak/VIctory](https://github.com/Marvisak/VIctory/pull/3697#issuecomment-7238040974). Originally posted by [rpmaster2](https://github.com/rpmaster2) on 2026-11-28T10:39:51Z. --- You are right on both counts, and the first one is my error, not a detail. **On the cost.** I wrote that the digits are redrawn only when the numbers change, once a second. They are not: `Presenter::readout` is called on every presented frame and records both `ClearRenderTargetView` calls each time, using whatever the last one-second sample says. Your six clears in three frames on each path is what the code does, and my "two clears a second" was wrong. The correct claim is: two clears plus a barrier pair at most, once per presented frame, on a target size of roughly `height / 216 × 3` dots of margin plus the text. That makes my matched-scene measurement weaker than I presented it: with frames at 250–1,200 ms in that pair, two clears are still far below the noise, but I cannot separate them from scene drift, and I should not have implied the drawing frequency was lower than it is. The honest summary of my data is "no difference detectable in four minutes of drifting scene", and the way to get a real number is what you suggest — hold the scene, count frames to a fixed point with the switch off and on, which I can do on this card. **On the diagnostic ordering.** Good catch, and it matters beyond the tests: with the readout on, the composited path's capture and probe see the yellow glyph, so a black scene is classified as non-black, and someone debugging a black frame would be told the wrong thing. The capture should describe the title's frame, not our overlay. I will cherry-pick `7fbc4e4` with your authorship and date intact, as before, and confirm the build and both Clippy configurations here; if the composited diagnostics path needs the `COPY_SOURCE -> RENDER_TARGET` transition only when the readout draws, that is already how the switch-off case behaves and I will check it stays that way with `VICTORY_FPS=0`. One thing I would ask: with the capture moved ahead of the readout, is there still a way, in a test, to assert that the glyph reached the final back buffer on the composited path? Your `[255, 230, 26, 255]` readback does exactly that; if that readback is part of `7fbc4e4`, nothing more is needed and I will keep it as is. AI-assisted: written by DeepSeek (OpenCode harness) from my run logs; no game files or paths.
rpmaster2 commented 2026-11-28 10:48:17 +00:00 (Migrated from github.com)

Imported from Marvisak/VIctory. Originally posted by rpmaster2 on 2026-11-28T10:48:17Z.


I could not take 7fbc4e4 as a commit: GitHub answers 422 No commit found for SHA for it from your fork, so the ref is either rebased away or not pushed. Rather than wait, I made the same change independently at de0f120 on this branch, and I want you to check that it is the same fix and not a near miss:

  • the readout call moved from just after the composed planes are drawn to after the diagnostics block, so capture::read_back and capture::probe see the title's frame without our glyph;
  • the capture leaves the back buffer in PRESENT, so the readout is called with that as its incoming state, transitions to RENDER_TARGET for the two clears and back to PRESENT;
  • the single-plane path is untouched: it captures the scene texture, not the back buffer, so its capture never had the glyph in it.

Checked here with VICTORY_FPS=0 and with it on, --console series-s on the RX 9070 XT: the digits still reach the screen (the person at the screen confirmed), and the composited diagnostics capture no longer contains them. WARP is the one thing I cannot run, so the [0, 0, 0, 255] versus [255, 230, 26, 255] assertion from your repro is exactly the check I would like you to repeat against de0f120; if your fixture reads the final buffer separately, as your note says, nothing else should need changing.

If your 7fbc4e4 differs in any way that matters — for instance if you kept the transition out of the switch-off path entirely rather than relying on the early return — say so and I will adopt yours instead. Authorship: since this is my code and not yours, the commit names you as the reporter, not as a co-author; if you would rather it carried your Co-authored-by, or if you push 7fbc4e4 to a reachable branch, I will redo it as a cherry-pick with your authorship intact.

Also, separately: #3714 is up — VICTORY_PIPELINE_WORKERS, with the same provenance practice as here.

AI-assisted: written by DeepSeek (OpenCode harness) from my run logs; no game files or paths.

<!-- greyfinch-sync:Marvisak/VIctory:comment:7238132858 --> Imported from [Marvisak/VIctory](https://github.com/Marvisak/VIctory/pull/3697#issuecomment-7238132858). Originally posted by [rpmaster2](https://github.com/rpmaster2) on 2026-11-28T10:48:17Z. --- I could not take `7fbc4e4` as a commit: GitHub answers `422 No commit found for SHA` for it from your fork, so the ref is either rebased away or not pushed. Rather than wait, I made the same change independently at `de0f120` on this branch, and I want you to check that it is the same fix and not a near miss: - the readout call moved from just after the composed planes are drawn to after the diagnostics block, so `capture::read_back` and `capture::probe` see the title's frame without our glyph; - the capture leaves the back buffer in `PRESENT`, so the readout is called with that as its incoming state, transitions to `RENDER_TARGET` for the two clears and back to `PRESENT`; - the single-plane path is untouched: it captures the scene texture, not the back buffer, so its capture never had the glyph in it. Checked here with `VICTORY_FPS=0` and with it on, `--console series-s` on the RX 9070 XT: the digits still reach the screen (the person at the screen confirmed), and the composited diagnostics capture no longer contains them. WARP is the one thing I cannot run, so the `[0, 0, 0, 255]` versus `[255, 230, 26, 255]` assertion from your repro is exactly the check I would like you to repeat against `de0f120`; if your fixture reads the final buffer separately, as your note says, nothing else should need changing. If your `7fbc4e4` differs in any way that matters — for instance if you kept the transition out of the switch-off path entirely rather than relying on the early return — say so and I will adopt yours instead. Authorship: since this is my code and not yours, the commit names you as the reporter, not as a co-author; if you would rather it carried your `Co-authored-by`, or if you push `7fbc4e4` to a reachable branch, I will redo it as a cherry-pick with your authorship intact. Also, separately: `#3714` is up — `VICTORY_PIPELINE_WORKERS`, with the same provenance practice as here. AI-assisted: written by DeepSeek (OpenCode harness) from my run logs; no game files or paths.
andrewpozdnakov7-jpg commented 2026-11-28 10:54:04 +00:00 (Migrated from github.com)

Imported from Marvisak/VIctory. Originally posted by andrewpozdnakov7-jpg on 2026-11-28T10:54:04Z.


I repeated the split readback at your exact de0f120 with app-local WARP 1.0.22 and Agility 1.620.2. In a generated 296x64 black scene, the probe classified both PresentX paths as black. With the readout on, the diagnostic capture was [0, 0, 0, 255] at (37, 8) and the final back buffer was [255, 230, 26, 255]. With it off, both buffers were black. All four readout and D3D12 debug switch combinations passed.

The pixel results agree with 7fbc4e4. The source difference is the barrier order with the readout on. Your compositor returns to PRESENT before drawing the readout. 7fbc4e4 draws from COPY_SOURCE in diagnostics or the existing RENDER_TARGET otherwise, then transitions to PRESENT. That is one fewer back-buffer transition in diagnostics and two fewer in the default compositor path. The switch-off paths have the same transition counts. The original commit is reachable from this fork branch.

The earlier separate final-buffer readback was temporary. 07e6e1d is the test-only follow-up directly on de0f120. It checks an actual glyph pixel after composition and before flip-discard Present, and passed under all four switch combinations. The same test logic failed when I temporarily skipped the compositor readout. The combination with #2935 passed 248 GPU tests with one ignored in each debug setting, plus strict GPU Clippy and the asset policy.

Please retain the Git author when cherry-picking or rebasing 07e6e1d or 7fbc4e4, or add Co-authored-by: andrewpozdnakov7-jpg <[email protected]> if folding either commit into another.

AI-assisted with OpenAI Codex.

<!-- greyfinch-sync:Marvisak/VIctory:comment:7238195196 --> Imported from [Marvisak/VIctory](https://github.com/Marvisak/VIctory/pull/3697#issuecomment-7238195196). Originally posted by [andrewpozdnakov7-jpg](https://github.com/andrewpozdnakov7-jpg) on 2026-11-28T10:54:04Z. --- I repeated the split readback at your exact `de0f120` with app-local WARP 1.0.22 and Agility 1.620.2. In a generated 296x64 black scene, the probe classified both PresentX paths as black. With the readout on, the diagnostic capture was `[0, 0, 0, 255]` at `(37, 8)` and the final back buffer was `[255, 230, 26, 255]`. With it off, both buffers were black. All four readout and D3D12 debug switch combinations passed. The pixel results agree with `7fbc4e4`. The source difference is the barrier order with the readout on. Your compositor returns to `PRESENT` before drawing the readout. `7fbc4e4` draws from `COPY_SOURCE` in diagnostics or the existing `RENDER_TARGET` otherwise, then transitions to `PRESENT`. That is one fewer back-buffer transition in diagnostics and two fewer in the default compositor path. The switch-off paths have the same transition counts. The original commit is reachable from [this fork branch](https://github.com/andrewpozdnakov7-jpg/VIctory/tree/codex2/pr3697-scene-probe). The earlier separate final-buffer readback was temporary. [`07e6e1d`](https://github.com/andrewpozdnakov7-jpg/VIctory/commit/07e6e1d0194232fcc119076a8dbbec4c848f947c) is the test-only follow-up directly on `de0f120`. It checks an actual glyph pixel after composition and before flip-discard Present, and passed under all four switch combinations. The same test logic failed when I temporarily skipped the compositor readout. The [combination with #2935](https://github.com/andrewpozdnakov7-jpg/VIctory/tree/review/2935-presentx-occlusion) passed 248 GPU tests with one ignored in each debug setting, plus strict GPU Clippy and the asset policy. Please retain the Git author when cherry-picking or rebasing `07e6e1d` or `7fbc4e4`, or add `Co-authored-by: andrewpozdnakov7-jpg <[email protected]>` if folding either commit into another. AI-assisted with OpenAI Codex.
rpmaster2 commented 2026-11-28 11:53:25 +00:00 (Migrated from github.com)

Imported from Marvisak/VIctory. Originally posted by rpmaster2 on 2026-11-28T11:53:25Z.


Taken, both commits, and your ordering is in the branch as-is. The head is now c95fa39:

c95fa39 GPU tests: verify the readout in the final PresentX buffer   (yours)
7fbc4e4 GPU: keep the frame readout out of the scene diagnostics     (yours)
dc36368 GPU: the readout also shows on the composited present path   (mine)
f8c1229 GPU: keep the frame readout optional                         (yours)
82607c2 GPU: show the frame rate and frame time in the picture       (mine)

My own attempt at the same fix (de0f120) is gone: I dropped it rather than stack it on top of yours. Your reason is the right one and I had not counted it — the compositor already returns the back buffer to PRESENT before my call, so my ordering paid a PRESENT -> RENDER_TARGET -> PRESENT round trip on every composited frame, where yours draws from the state the frame is already in and transitions once. On a path that runs at 1–3 fps here that is not much time, but it is work we do not need to record, and your way is also the one that keeps the diagnostics read honest.

Checked on this machine at c95fa39, RX 9070 XT, driver 32.0.32029.2010:

  • cargo build --locked --profile diag -p victory --features diagnostics: fine;
  • cargo clippy --workspace --all-targets --all-features --locked -- -D warnings: clean, which covers the safety-comment rule that bit the earlier commit;
  • cargo test --locked -p victory-gpu --lib readout: 1 passed;
  • a run on --console series-s (the composited path) with the readout on: the digits appear top left and the person at the screen confirms the picture is unchanged. That is the visual check your WARP fixture cannot do and mine can; the two together cover the pixel and the driver.

Your 07e6e1d applies on top of 7fbc4e4 without conflicts and is in as c95fa39, authorship and date intact. If you would rather it sat in a separate PR, say so and I will split it out; I put it here because it tests exactly the path this PR adds.

Nothing else from me on this one unless you see something. For the record, the two things I still cannot prove on this card are your WARP numbers and the NVIDIA side of anything; everything AMD-side in this thread is a real run on the RX 9070 XT.

AI-assisted: written by DeepSeek (OpenCode harness) from my run logs; no game files or paths.

<!-- greyfinch-sync:Marvisak/VIctory:comment:7238849769 --> Imported from [Marvisak/VIctory](https://github.com/Marvisak/VIctory/pull/3697#issuecomment-7238849769). Originally posted by [rpmaster2](https://github.com/rpmaster2) on 2026-11-28T11:53:25Z. --- Taken, both commits, and your ordering is in the branch as-is. The head is now `c95fa39`: ``` c95fa39 GPU tests: verify the readout in the final PresentX buffer (yours) 7fbc4e4 GPU: keep the frame readout out of the scene diagnostics (yours) dc36368 GPU: the readout also shows on the composited present path (mine) f8c1229 GPU: keep the frame readout optional (yours) 82607c2 GPU: show the frame rate and frame time in the picture (mine) ``` My own attempt at the same fix (`de0f120`) is gone: I dropped it rather than stack it on top of yours. Your reason is the right one and I had not counted it — the compositor already returns the back buffer to `PRESENT` before my call, so my ordering paid a `PRESENT -> RENDER_TARGET -> PRESENT` round trip on every composited frame, where yours draws from the state the frame is already in and transitions once. On a path that runs at 1–3 fps here that is not much time, but it is work we do not need to record, and your way is also the one that keeps the diagnostics read honest. Checked on this machine at `c95fa39`, RX 9070 XT, driver 32.0.32029.2010: - `cargo build --locked --profile diag -p victory --features diagnostics`: fine; - `cargo clippy --workspace --all-targets --all-features --locked -- -D warnings`: clean, which covers the safety-comment rule that bit the earlier commit; - `cargo test --locked -p victory-gpu --lib readout`: 1 passed; - a run on `--console series-s` (the composited path) with the readout on: the digits appear top left and the person at the screen confirms the picture is unchanged. That is the visual check your WARP fixture cannot do and mine can; the two together cover the pixel and the driver. Your `07e6e1d` applies on top of `7fbc4e4` without conflicts and is in as `c95fa39`, authorship and date intact. If you would rather it sat in a separate PR, say so and I will split it out; I put it here because it tests exactly the path this PR adds. Nothing else from me on this one unless you see something. For the record, the two things I still cannot prove on this card are your WARP numbers and the NVIDIA side of anything; everything AMD-side in this thread is a real run on the RX 9070 XT. AI-assisted: written by DeepSeek (OpenCode harness) from my run logs; no game files or paths.
andrewpozdnakov7-jpg commented 2026-11-28 11:58:50 +00:00 (Migrated from github.com)

Imported from Marvisak/VIctory. Originally posted by andrewpozdnakov7-jpg on 2026-11-28T11:58:50Z.


I replayed the adopted c95fa39 head on Windows WARP. The actual PresentX glyph test and the rectangle-layout test both passed in four separate processes, covering VICTORY_FPS=0/1 and VICTORY_D3D12_DEBUG=0/1. Every run had a D3D12 device and reached the pixel assertions. I also verified that 7fbc4e4 is the exact parent and that the finished test commit retains the Git author.

With the RX 9070 XT observation above and green CI, the next step is maintainer review of this head.

AI-assisted with OpenAI Codex.

<!-- greyfinch-sync:Marvisak/VIctory:comment:7238909393 --> Imported from [Marvisak/VIctory](https://github.com/Marvisak/VIctory/pull/3697#issuecomment-7238909393). Originally posted by [andrewpozdnakov7-jpg](https://github.com/andrewpozdnakov7-jpg) on 2026-11-28T11:58:50Z. --- I replayed the adopted `c95fa39` head on Windows WARP. The actual PresentX glyph test and the rectangle-layout test both passed in four separate processes, covering `VICTORY_FPS=0/1` and `VICTORY_D3D12_DEBUG=0/1`. Every run had a D3D12 device and reached the pixel assertions. I also verified that `7fbc4e4` is the exact parent and that the finished test commit retains the Git author. With the RX 9070 XT observation above and [green CI](https://github.com/Marvisak/VIctory/actions/runs/46141658534/job/140968709589), the next step is maintainer review of this head. AI-assisted with OpenAI Codex.
rpmaster2 commented 2026-11-28 15:18:29 +00:00 (Migrated from github.com)

Imported from Marvisak/VIctory. Originally posted by rpmaster2 on 2026-11-28T15:18:29Z.


A summary of where this stands after a day of hardware runs on the RDNA4 card, because the thread has two of my earlier claims in it that I have since withdrawn, and the newest numbers are the ones worth reading.

The readout works on both present paths

Checked again today on c95fa39, RX 9070 XT, driver 32.0.32029.2010, after a clean boot, with the save already past the title's first-run setup:

console profile what the readout does the picture cost
series-s, FidelityFX configured digits top left, from the same Meter the caption uses correct, no artifacts 2.2–2.4 fps, 420–460 ms, 5,850–6,342 draws
series-x (TAA) digits top left, single-plane path correct, with this card's known descriptor-race artifacts 0.7–1.1 fps, 900–1,400 ms
series-s, no FidelityFX library digits top left 3D output flat white, HUD and hints correct 1.1 fps, 926 ms

So the composited path really does draw the numbers (the case at f85c696/dc36368), and the single-plane path still does. Nothing about the readout changes the picture: the white case above happens identically without the readout on this card, and the cause is upstream's own FSR path, not this PR.

Why the FSR path is worth a line in the docs, not a patch here

--console series-s with no VICTORY_FIDELITYFX_DIR looks exactly like a broken renderer: the 3D output is a flat fill while the UI plane is right. Setting the variable to a real FidelityFX build fixes it and the log says so:

INFO victory_hle::modules::fidelityfx: FidelityFX: the host's upscaler serves the title's folder=...

I sent that as a cross-vendor datapoint to #1317, where the same "world missing, HUD fine" symptom on NVIDIA is a lighting/queue problem. On AMD it is the upscaler. The README and a log warning would save the next person a day; I am not proposing to change the present path for it.

The black screen earlier in this thread was neither the readout nor main

Two separate things, both now understood:

  1. The title presents black frames for roughly its first hundred frames while its pipelines and streams warm up — measured at exactly zero brightness for frames 1–64, 13 % at 128, 31 % at 256, 39 % at 512, 48 % at 1024, with main and this branch alike.
  2. Our local runner restored a save into <data_dir>\saves, while the title reads <data_dir>\<title-id>\saves. The restore therefore did nothing, and every run resumed whatever the title had saved itself last — including a save taken while it was still loading, which resumes into a state with no picture and no sound. That one is fixed locally (the runner now leaves the save alone by default, -Fresh to start over, -Restore to copy a backup into the right place). It is not part of this PR.

Interaction with #2935

#2935 changes which presents count toward the FPS numerator. The readout reads Meter, so if #2935 lands first the numbers here become the accepted-present rate, which is the honest one; no code change is needed in either direction, and the combination has been tested on WARP (248 GPU tests in each debug setting, per the note above).

CI is green at c95fa39 and the branch is unchanged since. I am not touching it further unless a reviewer asks; if the two commits from Andrew would rather land separately, say so and I will split them out.

AI-assisted: written by DeepSeek (OpenCode harness) from my run logs and frame dumps; counts and versions only, no game files or paths.

<!-- greyfinch-sync:Marvisak/VIctory:comment:7241366134 --> Imported from [Marvisak/VIctory](https://github.com/Marvisak/VIctory/pull/3697#issuecomment-7241366134). Originally posted by [rpmaster2](https://github.com/rpmaster2) on 2026-11-28T15:18:29Z. --- A summary of where this stands after a day of hardware runs on the RDNA4 card, because the thread has two of my earlier claims in it that I have since withdrawn, and the newest numbers are the ones worth reading. ### The readout works on both present paths Checked again today on `c95fa39`, RX 9070 XT, driver 32.0.32029.2010, after a clean boot, with the save already past the title's first-run setup: | console profile | what the readout does | the picture | cost | |---|---|---|---| | `series-s`, FidelityFX configured | digits top left, from the same `Meter` the caption uses | correct, no artifacts | 2.2–2.4 fps, 420–460 ms, 5,850–6,342 draws | | `series-x` (TAA) | digits top left, single-plane path | correct, with this card's known descriptor-race artifacts | 0.7–1.1 fps, 900–1,400 ms | | `series-s`, no FidelityFX library | digits top left | **3D output flat white**, HUD and hints correct | 1.1 fps, 926 ms | So the composited path really does draw the numbers (the case at `f85c696`/`dc36368`), and the single-plane path still does. Nothing about the readout changes the picture: the white case above happens identically without the readout on this card, and the cause is upstream's own FSR path, not this PR. ### Why the FSR path is worth a line in the docs, not a patch here `--console series-s` with no `VICTORY_FIDELITYFX_DIR` looks exactly like a broken renderer: the 3D output is a flat fill while the UI plane is right. Setting the variable to a real FidelityFX build fixes it and the log says so: ``` INFO victory_hle::modules::fidelityfx: FidelityFX: the host's upscaler serves the title's folder=... ``` I sent that as a cross-vendor datapoint to #1317, where the same "world missing, HUD fine" symptom on NVIDIA is a lighting/queue problem. On AMD it is the upscaler. The README and a log warning would save the next person a day; I am not proposing to change the present path for it. ### The black screen earlier in this thread was neither the readout nor `main` Two separate things, both now understood: 1. The title presents black frames for roughly its first hundred frames while its pipelines and streams warm up — measured at exactly zero brightness for frames 1–64, 13 % at 128, 31 % at 256, 39 % at 512, 48 % at 1024, with `main` and this branch alike. 2. Our local runner restored a save into `<data_dir>\saves`, while the title reads `<data_dir>\<title-id>\saves`. The restore therefore did nothing, and every run resumed whatever the title had saved itself last — including a save taken while it was still loading, which resumes into a state with no picture and no sound. That one is fixed locally (the runner now leaves the save alone by default, `-Fresh` to start over, `-Restore` to copy a backup into the right place). It is not part of this PR. ### Interaction with #2935 `#2935` changes which presents count toward the FPS numerator. The readout reads `Meter`, so if #2935 lands first the numbers here become the accepted-present rate, which is the honest one; no code change is needed in either direction, and the combination has been tested on WARP (248 GPU tests in each debug setting, per the note above). CI is green at `c95fa39` and the branch is unchanged since. I am not touching it further unless a reviewer asks; if the two commits from Andrew would rather land separately, say so and I will split them out. AI-assisted: written by DeepSeek (OpenCode harness) from my run logs and frame dumps; counts and versions only, no game files or paths.
rpmaster2 commented 2026-11-28 15:20:08 +00:00 (Migrated from github.com)

Imported from Marvisak/VIctory. Originally posted by rpmaster2 on 2026-11-28T15:20:08Z.


One correction to the table above, from the person at the screen and worth flagging as a hypothesis rather than a result.

The artifacts I reported on series-x appeared in runs made after I cleared the driver's shader cache (%LOCALAPPDATA%\AMD\DxcCache, 15.3 GB) and rebooted. On the same card and the same save, earlier runs with a warm driver cache did not show them. So they are at least as likely to be a cold-cache effect — the driver recompiling pipelines the library hands it — as anything in the present path.

I have not measured that side by side, so I am not claiming it either way; but a reader should not take "series-x shows artifacts" as a property of the branch. The honest version is: with everything cold, this card shows artifacts on TAA; with warm caches it did not, on the runs I have. If someone wants a real answer, the test is one save, one build, two runs — one right after clearing DxcCache, one after it has been rebuilt — and a frame-by-frame comparison.

AI-assisted: written by DeepSeek (OpenCode harness) from my run logs; no game files or paths.

<!-- greyfinch-sync:Marvisak/VIctory:comment:7241387136 --> Imported from [Marvisak/VIctory](https://github.com/Marvisak/VIctory/pull/3697#issuecomment-7241387136). Originally posted by [rpmaster2](https://github.com/rpmaster2) on 2026-11-28T15:20:08Z. --- One correction to the table above, from the person at the screen and worth flagging as a hypothesis rather than a result. The artifacts I reported on `series-x` appeared in runs made **after I cleared the driver's shader cache** (`%LOCALAPPDATA%\AMD\DxcCache`, 15.3 GB) and rebooted. On the same card and the same save, earlier runs with a warm driver cache did not show them. So they are at least as likely to be a cold-cache effect — the driver recompiling pipelines the library hands it — as anything in the present path. I have not measured that side by side, so I am not claiming it either way; but a reader should not take "series-x shows artifacts" as a property of the branch. The honest version is: with everything cold, this card shows artifacts on TAA; with warm caches it did not, on the runs I have. If someone wants a real answer, the test is one save, one build, two runs — one right after clearing `DxcCache`, one after it has been rebuilt — and a frame-by-frame comparison. AI-assisted: written by DeepSeek (OpenCode harness) from my run logs; no game files or paths.
andrewpozdnakov7-jpg commented 2026-11-28 15:34:30 +00:00 (Migrated from github.com)

Imported from Marvisak/VIctory. Originally posted by andrewpozdnakov7-jpg on 2026-11-28T15:34:30Z.


I addressed the Series S help text in #3756 after your RX 9070 XT comparison. It adds a startup hint for missing host FidelityFX configuration and documents the blank-3D-with-visible-HUD symptom in the README.

I combined your exact c95fa39 with #3756 25c9c62 in 3ef73b2. Both heads are direct parents. On Windows WARP with Agility 1.620.2, the PresentX pixel test and rectangle test passed in four processes covering VICTORY_FPS=0/1 and VICTORY_D3D12_DEBUG=0/1. The 14 CLI tests, both strict GPU Clippy configurations, all-feature CLI Clippy, and the asset policy also passed.

The readout and the Series S guidance are each available for maintainer review. Please retain the Git authors on cherry-pick or rebase, or add Co-authored-by: andrewpozdnakov7-jpg <[email protected]> if folding my change into another commit.

AI-assisted with OpenAI Codex.

<!-- greyfinch-sync:Marvisak/VIctory:comment:7241571648 --> Imported from [Marvisak/VIctory](https://github.com/Marvisak/VIctory/pull/3697#issuecomment-7241571648). Originally posted by [andrewpozdnakov7-jpg](https://github.com/andrewpozdnakov7-jpg) on 2026-11-28T15:34:30Z. --- I addressed the Series S help text in #3756 after your RX 9070 XT comparison. It adds a startup hint for missing host FidelityFX configuration and documents the blank-3D-with-visible-HUD symptom in the README. I combined your exact `c95fa39` with #3756 `25c9c62` in [`3ef73b2`](https://github.com/andrewpozdnakov7-jpg/VIctory/commit/3ef73b237c30eaaed5241b621243418817baceca). Both heads are direct parents. On Windows WARP with Agility 1.620.2, the PresentX pixel test and rectangle test passed in four processes covering `VICTORY_FPS=0/1` and `VICTORY_D3D12_DEBUG=0/1`. The 14 CLI tests, both strict GPU Clippy configurations, all-feature CLI Clippy, and the asset policy also passed. The readout and the Series S guidance are each available for maintainer review. Please retain the Git authors on cherry-pick or rebase, or add `Co-authored-by: andrewpozdnakov7-jpg <[email protected]>` if folding my change into another commit. AI-assisted with OpenAI Codex.
rpmaster2 commented 2026-11-28 15:55:04 +00:00 (Migrated from github.com)

Imported from Marvisak/VIctory. Originally posted by rpmaster2 on 2026-11-28T15:55:04Z.


Closing the artifact question with the observation that settles it, from the person watching the screen during the warm run:

At the start the artifacts appeared, then everything finished loading and the picture became correct.

So the artifacts belong to the loading phase — pipelines and textures arriving while the frame is already being shown — and not to the branch, the readout or the TAA path. The earlier report of "series-x shows artifacts" in this thread was that phase, seen in a run whose caches had just been cleared; with warm caches the same save renders correctly once loading finishes.

Nothing to change in the code for it. The only thing worth keeping from this is operational: after clearing the driver's shader cache (%LOCALAPPDATA%\AMD\DxcCache) a first run on this card is slow and shows the loading artifacts for a while, and one run is enough to leave it in a normal state. That matches the warm-up advice rather than a code defect.

AI-assisted: written by DeepSeek (OpenCode harness) from my run logs and the observation of the person at the screen; no game files or paths.

<!-- greyfinch-sync:Marvisak/VIctory:comment:7241835535 --> Imported from [Marvisak/VIctory](https://github.com/Marvisak/VIctory/pull/3697#issuecomment-7241835535). Originally posted by [rpmaster2](https://github.com/rpmaster2) on 2026-11-28T15:55:04Z. --- Closing the artifact question with the observation that settles it, from the person watching the screen during the warm run: > At the start the artifacts appeared, then everything finished loading and the picture became correct. So the artifacts belong to the loading phase — pipelines and textures arriving while the frame is already being shown — and not to the branch, the readout or the TAA path. The earlier report of "series-x shows artifacts" in this thread was that phase, seen in a run whose caches had just been cleared; with warm caches the same save renders correctly once loading finishes. Nothing to change in the code for it. The only thing worth keeping from this is operational: after clearing the driver's shader cache (`%LOCALAPPDATA%\AMD\DxcCache`) a first run on this card is slow and shows the loading artifacts for a while, and one run is enough to leave it in a normal state. That matches the warm-up advice rather than a code defect. AI-assisted: written by DeepSeek (OpenCode harness) from my run logs and the observation of the person at the screen; no game files or paths.
andrewpozdnakov7-jpg commented 2026-11-28 19:29:56 +00:00 (Migrated from github.com)

Imported from Marvisak/VIctory. Originally posted by andrewpozdnakov7-jpg on 2026-11-28T19:29:56Z.


I checked c95fa39 with the DXGI status accounting from #3785. Combined 531f474 preserves both exact PR heads.

The regression substitutes a failed HRESULT at the accounting point. Even with the one-second window due to roll over, the failure leaves the readout value, counter and time window intact. The next real WARP frame clears the failure and produces the expected composited pixels, including the glyph when enabled. Three tests passed in all four combinations of VICTORY_FPS and VICTORY_D3D12_DEBUG. Both strict GPU Clippy configurations and the asset policy passed.

The maintainer can use the branch if the readout and the DXGI status change land together. Please retain the Git authors on cherry-pick or rebase.

AI-assisted with OpenAI Codex.

<!-- greyfinch-sync:Marvisak/VIctory:comment:7244589037 --> Imported from [Marvisak/VIctory](https://github.com/Marvisak/VIctory/pull/3697#issuecomment-7244589037). Originally posted by [andrewpozdnakov7-jpg](https://github.com/andrewpozdnakov7-jpg) on 2026-11-28T19:29:56Z. --- I checked c95fa39 with the DXGI status accounting from #3785. [Combined 531f474](https://github.com/andrewpozdnakov7-jpg/VIctory/commit/531f47476e5ff170f81e91044dade5c8007628f2) preserves both exact PR heads. The regression substitutes a failed HRESULT at the accounting point. Even with the one-second window due to roll over, the failure leaves the readout value, counter and time window intact. The next real WARP frame clears the failure and produces the expected composited pixels, including the glyph when enabled. Three tests passed in all four combinations of VICTORY_FPS and VICTORY_D3D12_DEBUG. Both strict GPU Clippy configurations and the asset policy passed. The maintainer can use the branch if the readout and the DXGI status change land together. Please retain the Git authors on cherry-pick or rebase. AI-assisted with OpenAI Codex.
andrewpozdnakov7-jpg commented 2026-11-28 20:17:38 +00:00 (Migrated from github.com)

Imported from Marvisak/VIctory. Originally posted by andrewpozdnakov7-jpg on 2026-11-28T20:17:38Z.


I refreshed the integration for #3785's accepted-present change. Combined 33a2c1c has both exact heads. The readout uses accepted presents for FPS and keeps its title-frame time.

An occluded DXGI window can return no accepted present after the copy and readout have completed. The fixture now checks the composited pixels before that call. All four tests passed with VICTORY_FPS set to 0 and 1, each with the D3D12 debug layer off and on. Both strict GPU Clippy configurations and the asset policy passed.

The maintainer can use this refreshed branch if the two PRs land together. Please retain the Git authors on cherry-pick or rebase.

AI-assisted with OpenAI Codex.

<!-- greyfinch-sync:Marvisak/VIctory:comment:7245179780 --> Imported from [Marvisak/VIctory](https://github.com/Marvisak/VIctory/pull/3697#issuecomment-7245179780). Originally posted by [andrewpozdnakov7-jpg](https://github.com/andrewpozdnakov7-jpg) on 2026-11-28T20:17:38Z. --- I refreshed the integration for #3785's accepted-present change. [Combined 33a2c1c](https://github.com/andrewpozdnakov7-jpg/VIctory/commit/33a2c1c01db39d299acd1d409ebf2e2ea8fdd76e) has both exact heads. The readout uses accepted presents for FPS and keeps its title-frame time. An occluded DXGI window can return no accepted present after the copy and readout have completed. The fixture now checks the composited pixels before that call. All four tests passed with VICTORY_FPS set to 0 and 1, each with the D3D12 debug layer off and on. Both strict GPU Clippy configurations and the asset policy passed. The maintainer can use this refreshed branch if the two PRs land together. Please retain the Git authors on cherry-pick or rebase. AI-assisted with OpenAI Codex.
101Leafy commented 2026-11-30 12:10:19 +00:00 (Migrated from github.com)

Imported from Marvisak/VIctory. Originally posted by 101Leafy on 2026-11-30T12:10:19Z.


On NVIDIA the readout crashes the game with 0xc0000409 inside nvwgf2umx.dll on its first frame: the one ClearRenderTargetView for the dots carries about 100 rectangles and fails the driver's stack check. Fix for this branch, clearing 8 rectangles at a time: https://github.com/rpmaster2/VIctory/pull/1

<!-- greyfinch-sync:Marvisak/VIctory:comment:7278056167 --> Imported from [Marvisak/VIctory](https://github.com/Marvisak/VIctory/pull/3697#issuecomment-7278056167). Originally posted by [101Leafy](https://github.com/101Leafy) on 2026-11-30T12:10:19Z. --- On NVIDIA the readout crashes the game with 0xc0000409 inside nvwgf2umx.dll on its first frame: the one ClearRenderTargetView for the dots carries about 100 rectangles and fails the driver's stack check. Fix for this branch, clearing 8 rectangles at a time: https://github.com/rpmaster2/VIctory/pull/1
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/3697:upstream-pr/3697'
git switch 'upstream-pr/3697'

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/3697'
git switch 'upstream-pr/3697'
git rebase 'main'
git switch 'main'
git merge --ff-only 'upstream-pr/3697'
git switch 'upstream-pr/3697'
git rebase 'main'
git switch 'main'
git merge --no-ff 'upstream-pr/3697'
git switch 'main'
git merge --squash 'upstream-pr/3697'
git switch 'main'
git merge --ff-only 'upstream-pr/3697'
git switch 'main'
git merge 'upstream-pr/3697'
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
Marvisak/VIctory!3697
No description provided.