D3D12.X: seek to textures overlapping sparse CPU writes #1086

Open
github-bot wants to merge 2 commits from github-bot/gh-1086 into main AGit
Owner

@⁠TG0000 on GitHub · 2026-11-24 11:25 UTC · original
TG0000:perf/dirty-texture-candidates → main · +300 −42 · 1 files · 2 commits · open

Each submit that finds written pages checked every tracked title texture against the list of written pages, even when only a few pages were written. A sparse submit now seeks the overlapping textures through the existing by_va placement index. Textures whose CPU source differs from their placement are kept in a small set and checked separately. Pending first uploads and dense writes keep the full scan, and the resulting upload order is unchanged.

Related to #582, but it does not change GetWriteWatch, which that issue measured as 99.7 % of a look. This is a saving of microseconds per submit in the selection step, not an expected frame-rate gain.

What is in it

  • crates/xcl/src/hle/d3d12x/title_textures.rs: indexed selection of upload candidates; insert_active / remove_active keep the remapped set in step with the placement index; a test against the full scan (aliases, remapped sources, shadowed and restored placements, GPU-written and pending textures, dense writes); a manual release benchmark (#[ignore]).
  • Review follow-up (7d92772), same file: the remapped update of recheck_gpu_view_sources is now Table::recheck_sources, so it runs without a GPU. a_source_that_flips_keeps_the_sparse_selection_exact has 26 textures, flips one source each way (and back) and compares collect_uploads with linear_upload_keys after every flip.

Tested

  • Ryzen 9 5900X, Radeon RX 6800 (driver 32.0.21045.29003), Windows build 26300, Rust 1.100.0 MSVC. Debug workspace and release xcl builds.
  • cargo test --workspace --no-fail-fast -- --test-threads=4 --show-output: 735 passed, 3 failed, 42 ignored on this head; 734 passed, 3 failed, 41 ignored on main 384f7f7. The same three fail in both: placed_title_textures_share_vram_and_preserve_pixels (3D texture, subresource 2 mismatch), and transitions_apply_when_their_list_is_submitted and d32s8_targets_take_their_own_size_of_video_memory on the lock it poisons.
  • SKIPPED in both, no D3D12 debug layer: test_title_draws_with_a_root_signature_under_the_debug_layer, uploads_start_from_each_subresources_state.
  • cargo clippy -p xcl --lib --tests (before the rebase, same patch): no warnings on the changed lines.
  • Follow-up commit 7d92772: cargo test -p xcl --lib d3d12x::title_textures -- --test-threads=4: 14 passed, 1 failed, 1 ignored (the benchmark). The failure is placed_title_textures_share_vram_and_preserve_pixels (3D texture, subresource 2 mismatch), which fails the same way on 3d5e3b1 (13 passed, 1 failed, 1 ignored). With the remapped update removed from recheck_sources, the new test fails. cargo clippy -p xcl --lib --tests: no warning on the changed lines. Same machine as above; the whole workspace was not run again for this commit.
  • cargo test --release -p xcl --lib bench_dirty_texture_candidates -- --ignored --nocapture, median of seven rounds, synthetic textures, µs per submit for the selection alone:
textures pages written full scan this PR
512 4 4.029 0.307 13.1x
512 16 6.199 1.897 3.3x
4096 4 40.353 0.368 109.5x
4096 16 53.251 2.173 24.5x
8192 4 99.095 0.406 244.2x

The ratio varies by run: two earlier runs of the 4096 / 4 row measured 72x and 90x.

Regression run

On the head 7d92772 and on its merge base with main, 384f7f7: one release build and one run each, from clean trees at those commits, the same title and 45 s. Other builds and tests ran on the PC during both runs, so the frame counts are not a timing comparison. Head: 1048 frames, main: 962; peak commit 15136 MB against 15133 MB; no device removal and no crash.

main:

xcl-smoke v1
commit: 384f7f7f8c79fa4d4dee59336d650a4021af4c7e
gpu: AMD Radeon RX 6800
title: retail-title-1.0.2.1
seconds: 45
exit: 0x0
frames shown: 962 (PresentX 962)
presents per 2 s (last 3): 60 60 60
device removals: 0
crashes: 0
peak commit: 15133 MB

PR:

xcl-smoke v1
commit: 7d9277246277acb85a0a982a4a6b29ff1a1640d4
gpu: AMD Radeon RX 6800
title: retail-title-1.0.2.1
seconds: 45
exit: 0x0
frames shown: 1048 (PresentX 1048)
presents per 2 s (last 3): 60 60 60
device removals: 0
crashes: 0
peak commit: 15136 MB

Earlier runs, on 3d5e3b1 (before the review follow-up). The first pair, main then PR. The title line is the folder name, replaced with a neutral label; everything else is as smoke.ps1 printed it.

main:

xcl-smoke v1
commit: 384f7f7f8c79fa4d4dee59336d650a4021af4c7e
gpu: AMD Radeon RX 6800
title: retail-title-1.0.2.1
seconds: 45
exit: 0x0
frames shown: 1036 (PresentX 1037)
presents per 2 s (last 3): 60 60 60
device removals: 0
crashes: 0
peak commit: 15113 MB

PR:

xcl-smoke v1
commit: 3d5e3b139717b95ef16d44830e7615c6535a2079
gpu: AMD Radeon RX 6800
title: retail-title-1.0.2.1
seconds: 45
exit: 0x0
frames shown: 977 (PresentX 977)
presents per 2 s (last 3): 60 60 46
device removals: 0
crashes: 0
peak commit: 15513 MB

All five pairs of those two builds, frames shown (no crash and no device removal in any):

pair run first main PR
1 main 1036 977
2 main 1039 991
3 PR 986 787
4 PR 1045 1011
5 PR 1017 1034

Other builds ran on the PC during several of these, and I found no mechanism for a slowdown, but the PR's median is 4 % lower and its third run is below 80 % of main's, so a small cost is not ruled out. Runs 1 and 2 of the PR and run 3 of main peaked at about 15.5 GB, the others at about 15.1 GB. A run on a quiet PC is welcome.

Not tested

  • NVIDIA, Intel, Wine, past the first menus, time spent in the selection inside a title.
  • A texture whose source is rechecked while it is shadowed adds to PENDING and nothing takes that count back (existing behaviour, read in the code, not reproduced). Where that happens PENDING stays above zero and every look uses the full scan, as before.
  • #877 changes the same filter (content hashes under Wine) and needs a manual merge with this one. #455, #640, #751 and #782 edit the same function near it. #1102 (draft, stacked on #1055) rewrites the same loop in recheck_gpu_view_sources (a Source enum in place of src) and adds a second path there through t.get_mut(res), so remapped has to be kept right on that path too when the two meet. #1182 (open) touches this file only in the tests module (one new GPU test), plus vram.rs and kernelx.rs; it does not change the code here.

AI use

  • Codex in T3 Code with GPT 6.2 Sol wrote the change, the test and the benchmark. Claude Code with Claude Opus 5.5 reviewed the diff, ran the tests, benchmark and smoke runs, and wrote this description. Claude Code with Claude Sonnet 5.5 wrote the review follow-up commit (Table::recheck_sources and its test) and updated this description for it.
**@⁠TG0000** on GitHub · 2026-11-24 11:25 UTC · [original](https://github.com/xcl-dev/xcl/pull/1086) `TG0000:perf/dirty-texture-candidates` → `main` · +300 −42 · 1 files · 2 commits · open Each submit that finds written pages checked every tracked title texture against the list of written pages, even when only a few pages were written. A sparse submit now seeks the overlapping textures through the existing `by_va` placement index. Textures whose CPU source differs from their placement are kept in a small set and checked separately. Pending first uploads and dense writes keep the full scan, and the resulting upload order is unchanged. Related to #582, but it does not change `GetWriteWatch`, which that issue measured as 99.7 % of a look. This is a saving of microseconds per submit in the selection step, not an expected frame-rate gain. **What is in it** - `crates/xcl/src/hle/d3d12x/title_textures.rs`: indexed selection of upload candidates; `insert_active` / `remove_active` keep the remapped set in step with the placement index; a test against the full scan (aliases, remapped sources, shadowed and restored placements, GPU-written and pending textures, dense writes); a manual release benchmark (`#[ignore]`). - Review follow-up (`7d92772`), same file: the `remapped` update of `recheck_gpu_view_sources` is now `Table::recheck_sources`, so it runs without a GPU. `a_source_that_flips_keeps_the_sparse_selection_exact` has 26 textures, flips one source each way (and back) and compares `collect_uploads` with `linear_upload_keys` after every flip. **Tested** - Ryzen 9 5900X, Radeon RX 6800 (driver 32.0.21045.29003), Windows build 26300, Rust 1.100.0 MSVC. Debug workspace and release `xcl` builds. - `cargo test --workspace --no-fail-fast -- --test-threads=4 --show-output`: 735 passed, 3 failed, 42 ignored on this head; 734 passed, 3 failed, 41 ignored on `main` `384f7f7`. The same three fail in both: `placed_title_textures_share_vram_and_preserve_pixels` (3D texture, subresource 2 mismatch), and `transitions_apply_when_their_list_is_submitted` and `d32s8_targets_take_their_own_size_of_video_memory` on the lock it poisons. - SKIPPED in both, no D3D12 debug layer: `test_title_draws_with_a_root_signature_under_the_debug_layer`, `uploads_start_from_each_subresources_state`. - `cargo clippy -p xcl --lib --tests` (before the rebase, same patch): no warnings on the changed lines. - Follow-up commit `7d92772`: `cargo test -p xcl --lib d3d12x::title_textures -- --test-threads=4`: 14 passed, 1 failed, 1 ignored (the benchmark). The failure is `placed_title_textures_share_vram_and_preserve_pixels` (3D texture, subresource 2 mismatch), which fails the same way on `3d5e3b1` (13 passed, 1 failed, 1 ignored). With the `remapped` update removed from `recheck_sources`, the new test fails. `cargo clippy -p xcl --lib --tests`: no warning on the changed lines. Same machine as above; the whole workspace was not run again for this commit. - `cargo test --release -p xcl --lib bench_dirty_texture_candidates -- --ignored --nocapture`, median of seven rounds, synthetic textures, µs per submit for the selection alone: | textures | pages written | full scan | this PR | | |---|---|---|---|---| | 512 | 4 | 4.029 | 0.307 | 13.1x | | 512 | 16 | 6.199 | 1.897 | 3.3x | | 4096 | 4 | 40.353 | 0.368 | 109.5x | | 4096 | 16 | 53.251 | 2.173 | 24.5x | | 8192 | 4 | 99.095 | 0.406 | 244.2x | The ratio varies by run: two earlier runs of the 4096 / 4 row measured 72x and 90x. **Regression run** On the head `7d92772` and on its merge base with main, `384f7f7`: one release build and one run each, from clean trees at those commits, the same title and 45 s. Other builds and tests ran on the PC during both runs, so the frame counts are not a timing comparison. Head: 1048 frames, main: 962; peak commit 15136 MB against 15133 MB; no device removal and no crash. main: ``` xcl-smoke v1 commit: 384f7f7f8c79fa4d4dee59336d650a4021af4c7e gpu: AMD Radeon RX 6800 title: retail-title-1.0.2.1 seconds: 45 exit: 0x0 frames shown: 962 (PresentX 962) presents per 2 s (last 3): 60 60 60 device removals: 0 crashes: 0 peak commit: 15133 MB ``` PR: ``` xcl-smoke v1 commit: 7d9277246277acb85a0a982a4a6b29ff1a1640d4 gpu: AMD Radeon RX 6800 title: retail-title-1.0.2.1 seconds: 45 exit: 0x0 frames shown: 1048 (PresentX 1048) presents per 2 s (last 3): 60 60 60 device removals: 0 crashes: 0 peak commit: 15136 MB ``` Earlier runs, on `3d5e3b1` (before the review follow-up). The first pair, main then PR. The title line is the folder name, replaced with a neutral label; everything else is as `smoke.ps1` printed it. main: ``` xcl-smoke v1 commit: 384f7f7f8c79fa4d4dee59336d650a4021af4c7e gpu: AMD Radeon RX 6800 title: retail-title-1.0.2.1 seconds: 45 exit: 0x0 frames shown: 1036 (PresentX 1037) presents per 2 s (last 3): 60 60 60 device removals: 0 crashes: 0 peak commit: 15113 MB ``` PR: ``` xcl-smoke v1 commit: 3d5e3b139717b95ef16d44830e7615c6535a2079 gpu: AMD Radeon RX 6800 title: retail-title-1.0.2.1 seconds: 45 exit: 0x0 frames shown: 977 (PresentX 977) presents per 2 s (last 3): 60 60 46 device removals: 0 crashes: 0 peak commit: 15513 MB ``` All five pairs of those two builds, frames shown (no crash and no device removal in any): | pair | run first | main | PR | |---|---|---|---| | 1 | main | 1036 | 977 | | 2 | main | 1039 | 991 | | 3 | PR | 986 | 787 | | 4 | PR | 1045 | 1011 | | 5 | PR | 1017 | 1034 | Other builds ran on the PC during several of these, and I found no mechanism for a slowdown, but the PR's median is 4 % lower and its third run is below 80 % of main's, so a small cost is not ruled out. Runs 1 and 2 of the PR and run 3 of main peaked at about 15.5 GB, the others at about 15.1 GB. A run on a quiet PC is welcome. **Not tested** - NVIDIA, Intel, Wine, past the first menus, time spent in the selection inside a title. - A texture whose source is rechecked while it is shadowed adds to `PENDING` and nothing takes that count back (existing behaviour, read in the code, not reproduced). Where that happens `PENDING` stays above zero and every look uses the full scan, as before. - #877 changes the same filter (content hashes under Wine) and needs a manual merge with this one. #455, #640, #751 and #782 edit the same function near it. #1102 (draft, stacked on #1055) rewrites the same loop in `recheck_gpu_view_sources` (a `Source` enum in place of `src`) and adds a second path there through `t.get_mut(res)`, so `remapped` has to be kept right on that path too when the two meet. #1182 (open) touches this file only in the tests module (one new GPU test), plus `vram.rs` and `kernelx.rs`; it does not change the code here. **AI use** - Codex in T3 Code with GPT 6.2 Sol wrote the change, the test and the benchmark. Claude Code with Claude Opus 5.5 reviewed the diff, ran the tests, benchmark and smoke runs, and wrote this description. Claude Code with Claude Sonnet 5.5 wrote the review follow-up commit (`Table::recheck_sources` and its test) and updated this description for it.
Use the placement index to select uploads when a submit dirties a few pages. Check remapped CPU sources separately and preserve resource order. First uploads and dense writes still use the full scan.

Co-Authored-By: GPT 6.2 Sol <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Review of #1086: nothing reached the `remapped` update in
recheck_gpu_view_sources, which needs a GPU. The update moves into
Table::recheck_sources (same loop, same order, shadowed textures too), and
a test with 26 textures flips one source each way (and one back) and
compares collect_uploads with linear_upload_keys after every flip. Without
the update the test fails.

Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-26 04:42:57 +00:00
Author
Owner

@⁠pvfreis on GitHub · 2026-11-24 14:06 UTC · original

Follow-up at 7d92772. I read the diff only; nothing was built or run here.

  • Point 1 is fixed. The remapped update is now Table::recheck_sources (title_textures.rs:131-147), with the same two loops in the same order. recheck_gpu_view_sources calls it at :516. The guard there is a temporary, so the lock is still released before TEXTURES_GEN is bumped, as before. a_source_that_flips_keeps_the_sparse_selection_exact (:1690-1752) checks that each look takes the sparse path, asserts the remapped set after every flip, and compares collect_uploads with linear_upload_keys. Dropping the update would fail it.
  • Point 2 is fixed: #1102 is in the overlap list. Points 3 and 4 needed no change.
  • Still open before merging: PR checks now fails at 7d92772 because the Regression run block names 3d5e3b1, and the check wants an xcl-smoke block made on 7d92772. CI shows action_required at this head, so it has not run yet.

Reply by Claude Code (Claude Opus 5.5); checked by a person before posting.

**@⁠pvfreis** on GitHub · 2026-11-24 14:06 UTC · [original](https://github.com/xcl-dev/xcl/pull/1086#issuecomment-7133851202) Follow-up at `7d92772`. I read the diff only; nothing was built or run here. - Point 1 is fixed. The `remapped` update is now `Table::recheck_sources` (`title_textures.rs:131-147`), with the same two loops in the same order. `recheck_gpu_view_sources` calls it at `:516`. The guard there is a temporary, so the lock is still released before `TEXTURES_GEN` is bumped, as before. `a_source_that_flips_keeps_the_sparse_selection_exact` (`:1690-1752`) checks that each look takes the sparse path, asserts the `remapped` set after every flip, and compares `collect_uploads` with `linear_upload_keys`. Dropping the update would fail it. - Point 2 is fixed: #1102 is in the overlap list. Points 3 and 4 needed no change. - Still open before merging: `PR checks` now fails at `7d92772` because the **Regression run** block names `3d5e3b1`, and the check wants an `xcl-smoke` block made on `7d92772`. `CI` shows `action_required` at this head, so it has not run yet. Reply by Claude Code (Claude Opus 5.5); checked by a person before posting.
Author
Owner

@⁠fromthemoonx on GitHub · 2026-11-24 12:02 UTC · original · edited 2026-11-24 14:07 UTC

Rerun on the new head 7d9277246277acb85a0a982a4a6b29ff1a1640d4 (same machine, debug), which your follow-up did not run as a whole:

  • cargo build --workspace, then cargo test --workspace --no-fail-fast -- --test-threads=4: 739 passed, 0 failed, 42 ignored; placed_title_textures_share_vram_and_preserve_pixels passes here, as before
  • Merged onto current main 930e8b4 (no conflict): 753 passed, 0 failed, 42 ignored
  • The new test fails without the remapped update, as you say: with the two remapped lines in Table::recheck_sources removed, a_source_that_flips_keeps_the_sparse_selection_exact fails with left: [25], right: [5, 25]
  • hle::d3d12x::title_textures + hle::d3d12x::vram tests, 10 runs: 10 of 10 passed (22 passed, 1 ignored each)
  • D3D12 debug layer: the e2e test title's run on the merged tree logs the same debug-layer error and warning ids as on main 930e8b4

The first run, on 3d5e3b1, follows unchanged.


NVIDIA run, since Not tested lists NVIDIA. This machine has the D3D12 debug layer installed, so the two tests that were SKIPPED in your run ran here.

Tested

  • NVIDIA GeForce RTX 3060 12 GB (32-lane waves), driver 32.0.16.1088; AMD Ryzen 7 5700X; native Windows 11 Pro 26H2 (build 26300.9974), Graphics Tools (D3D12 debug layer) installed; rustc 1.100.0 stable-x86_64-pc-windows-msvc; DXC 1.9.2602.17

  • Exact head 3d5e3b139717b95ef16d44830e7615c6535a2079 (on its base 384f7f7), debug: cargo build --workspace, then cargo test --workspace --no-fail-fast -- --test-threads=4: 738 passed, 0 failed, 42 ignored (lib 695 / 0 / 22). Notable:

    • the new dirty_texture_candidates_match_the_full_scan passed
    • the three that fail in your RX 6800 run pass here: placed_title_textures_share_vram_and_preserve_pixels, transitions_apply_when_their_list_is_submitted, d32s8_targets_take_their_own_size_of_video_memory
    • the two you had SKIPPED ran and passed: test_title_draws_with_a_root_signature_under_the_debug_layer, uploads_start_from_each_subresources_state
  • Merged onto current main 47efa2e (no conflict): 742 passed, 0 failed, 42 ignored

  • hle::d3d12x::title_textures + hle::d3d12x::vram tests on the merged tree, 10 runs: 10 of 10 passed (23 passed, 1 ignored each)

  • D3D12 debug layer: the e2e test title's XCL_D3D12_DEBUG=1 run logs the same set of debug-layer errors and warnings on the merged tree as on main.

  • Release benchmark (cargo test --release -p xcl --lib bench_dirty_texture_candidates -- --ignored --nocapture), one run, µs per submit for the selection:

    textures pages full scan this PR
    512 1 / 4 / 16 2.29 / 3.66 / 4.95 0.13 / 0.32 / 1.67 18× / 11× / 3.0×
    4096 1 / 4 / 16 22.9 / 28.8 / 35.9 0.15 / 0.34 / 2.07 154× / 86× / 17×
    8192 1 / 4 / 16 44.8 / 62.1 / 83.7 0.14 / 0.39 / 2.59 320× / 158× / 32×

    Same shape as yours: the full scan is faster on this CPU, so the ratios differ, but the PR's times are close to yours.

  • SKIPPED (no wave64 on this adapter): gpu_geometry_wave32_prefix_count_over_a_mask, gpu_wave32_program_in_wave64_hardware

Not tested

  • A retail title (no smoke.ps1 here); the benchmark is synthetic, and as you say the saving is per submit, not frame rate.

AI use

  • Claude Code (Claude Opus 5.5) ran the builds, tests and benchmark on the machine above and wrote this report from the output.
**@⁠fromthemoonx** on GitHub · 2026-11-24 12:02 UTC · [original](https://github.com/xcl-dev/xcl/pull/1086#issuecomment-7130873171) · edited 2026-11-24 14:07 UTC **Rerun on the new head `7d9277246277acb85a0a982a4a6b29ff1a1640d4`** (same machine, debug), which your follow-up did not run as a whole: - `cargo build --workspace`, then `cargo test --workspace --no-fail-fast -- --test-threads=4`: **739 passed, 0 failed, 42 ignored**; `placed_title_textures_share_vram_and_preserve_pixels` passes here, as before - **Merged onto current `main` `930e8b4`** (no conflict): **753 passed, 0 failed, 42 ignored** - **The new test fails without the `remapped` update**, as you say: with the two `remapped` lines in `Table::recheck_sources` removed, `a_source_that_flips_keeps_the_sparse_selection_exact` fails with `left: [25], right: [5, 25]` - `hle::d3d12x::title_textures` + `hle::d3d12x::vram` tests, 10 runs: **10 of 10 passed** (22 passed, 1 ignored each) - D3D12 debug layer: the e2e test title's run on the merged tree logs the same debug-layer error and warning ids as on `main` `930e8b4` The first run, on `3d5e3b1`, follows unchanged. --- NVIDIA run, since **Not tested** lists NVIDIA. This machine has the D3D12 debug layer installed, so the two tests that were SKIPPED in your run ran here. **Tested** - NVIDIA GeForce RTX 3060 12 GB (32-lane waves), driver 32.0.16.1088; AMD Ryzen 7 5700X; native Windows 11 Pro 26H2 (build 26300.9974), Graphics Tools (D3D12 debug layer) installed; rustc 1.100.0 `stable-x86_64-pc-windows-msvc`; DXC 1.9.2602.17 - **Exact head `3d5e3b139717b95ef16d44830e7615c6535a2079`** (on its base `384f7f7`), debug: `cargo build --workspace`, then `cargo test --workspace --no-fail-fast -- --test-threads=4`: **738 passed, 0 failed, 42 ignored** (lib 695 / 0 / 22). Notable: - the new `dirty_texture_candidates_match_the_full_scan` passed - the three that fail in your RX 6800 run pass here: `placed_title_textures_share_vram_and_preserve_pixels`, `transitions_apply_when_their_list_is_submitted`, `d32s8_targets_take_their_own_size_of_video_memory` - the two you had SKIPPED ran and passed: `test_title_draws_with_a_root_signature_under_the_debug_layer`, `uploads_start_from_each_subresources_state` - **Merged onto current `main` `47efa2e`** (no conflict): **742 passed, 0 failed, 42 ignored** - `hle::d3d12x::title_textures` + `hle::d3d12x::vram` tests on the merged tree, 10 runs: **10 of 10 passed** (23 passed, 1 ignored each) - D3D12 debug layer: the e2e test title's `XCL_D3D12_DEBUG=1` run logs the same set of debug-layer errors and warnings on the merged tree as on `main`. - Release benchmark (`cargo test --release -p xcl --lib bench_dirty_texture_candidates -- --ignored --nocapture`), one run, µs per submit for the selection: | textures | pages | full scan | this PR | | |---|---|---|---|---| | 512 | 1 / 4 / 16 | 2.29 / 3.66 / 4.95 | 0.13 / 0.32 / 1.67 | 18× / 11× / 3.0× | | 4096 | 1 / 4 / 16 | 22.9 / 28.8 / 35.9 | 0.15 / 0.34 / 2.07 | 154× / 86× / 17× | | 8192 | 1 / 4 / 16 | 44.8 / 62.1 / 83.7 | 0.14 / 0.39 / 2.59 | 320× / 158× / 32× | Same shape as yours: the full scan is faster on this CPU, so the ratios differ, but the PR's times are close to yours. - SKIPPED (no wave64 on this adapter): `gpu_geometry_wave32_prefix_count_over_a_mask`, `gpu_wave32_program_in_wave64_hardware` **Not tested** - A retail title (no `smoke.ps1` here); the benchmark is synthetic, and as you say the saving is per submit, not frame rate. **AI use** - Claude Code (Claude Opus 5.5) ran the builds, tests and benchmark on the machine above and wrote this report from the output.
Author
Owner

@⁠JoaoPauluu on GitHub · 2026-11-24 14:21 UTC · original

A regression run under Wine on Linux, on a retail title.

Tested

  • RTX 3060 12 GB (NVIDIA 620.70.06, 32-lane waves), i5-10400F, 16 GB, CachyOS (kernel 7.3.3), Proton Experimental 11.0-20261112 with the patched vkd3d-proton 3.1 from #257, DXC 1.9.2609.5. Release, cross-built for x86_64-pc-windows-gnu. 7d92772 as it is (merge base 384f7f7) and main 47efa2e, no uncommitted changes. Retail title 1.0.2.1, scripts/linux/smoke.sh (#257) for 60 s, no input. Twelve runs in a row, main first and last, other PRs in between.
  • This PR's merge base is 384f7f7; the main runs are of 47efa2e, a later commit of main.

Regression run

main (first run):

xcl-smoke v1
commit: 47efa2ecea0a12934719ae69b81930cf02a4b1c3
gpu: NVIDIA GeForce RTX 3060
title: GTA6.Xbox.v1.0.2.1
seconds: 60
exit: 0x0
frames shown: 1384 (PresentX 1384)
presents per 2 s (last 3): 60 60 60
device removals: 0
crashes: 0
peak commit: 0 MB

this PR:

xcl-smoke v1
commit: 7d9277246277acb85a0a982a4a6b29ff1a1640d4
gpu: NVIDIA GeForce RTX 3060
title: GTA6.Xbox.v1.0.2.1
seconds: 60
exit: 0x0
frames shown: 1424 (PresentX 1424)
presents per 2 s (last 3): 60 60 60
device removals: 0
crashes: 0
peak commit: 0 MB

The last main run: 1425 frames, exit: 0x0, no device removal, no crash. Under Wine, peak commit reads 0 MB, so these blocks do not check memory.

Not tested

  • the test suite on this head; native Windows; AMD.

AI use

  • Claude Code (Claude Opus 5.5) built both commits, ran the runs and wrote this report. The account owner asked for test reports to be posted and has not reviewed this one.
**@⁠JoaoPauluu** on GitHub · 2026-11-24 14:21 UTC · [original](https://github.com/xcl-dev/xcl/pull/1086#issuecomment-7134248906) A regression run under Wine on Linux, on a retail title. **Tested** - RTX 3060 12 GB (NVIDIA 620.70.06, 32-lane waves), i5-10400F, 16 GB, CachyOS (kernel 7.3.3), Proton Experimental 11.0-20261112 with the patched vkd3d-proton 3.1 from #257, DXC 1.9.2609.5. Release, cross-built for `x86_64-pc-windows-gnu`. `7d92772` as it is (merge base `384f7f7`) and `main` `47efa2e`, no uncommitted changes. Retail title 1.0.2.1, `scripts/linux/smoke.sh` (#257) for 60 s, no input. Twelve runs in a row, `main` first and last, other PRs in between. - This PR's merge base is `384f7f7`; the `main` runs are of `47efa2e`, a later commit of `main`. **Regression run** main (first run): ``` xcl-smoke v1 commit: 47efa2ecea0a12934719ae69b81930cf02a4b1c3 gpu: NVIDIA GeForce RTX 3060 title: GTA6.Xbox.v1.0.2.1 seconds: 60 exit: 0x0 frames shown: 1384 (PresentX 1384) presents per 2 s (last 3): 60 60 60 device removals: 0 crashes: 0 peak commit: 0 MB ``` this PR: ``` xcl-smoke v1 commit: 7d9277246277acb85a0a982a4a6b29ff1a1640d4 gpu: NVIDIA GeForce RTX 3060 title: GTA6.Xbox.v1.0.2.1 seconds: 60 exit: 0x0 frames shown: 1424 (PresentX 1424) presents per 2 s (last 3): 60 60 60 device removals: 0 crashes: 0 peak commit: 0 MB ``` The last `main` run: 1425 frames, `exit: 0x0`, no device removal, no crash. Under Wine, `peak commit` reads 0 MB, so these blocks do not check memory. **Not tested** - the test suite on this head; native Windows; AMD. **AI use** - Claude Code (Claude Opus 5.5) built both commits, ran the runs and wrote this report. The account owner asked for test reports to be posted and has not reviewed this one.
Author
Owner

@⁠TG0000 on GitHub · 2026-11-24 13:58 UTC · original · edited 2026-11-24 16:45 UTC

Thank you for the careful review. I checked each point against the code.

Pushed 7d92772 on top of 3d5e3b1 (no force push):

  • Point 1: the remapped update moved into Table::recheck_sources, so it runs without a GPU. The new test a_source_that_flips_keeps_the_sparse_selection_exact has 26 textures, flips one source each way (and back, twice) and compares collect_uploads with linear_upload_keys after every flip. It also flips a shadowed texture. With the remapped update removed from the method, it fails.
  • Point 2: #1102 added to the overlap list in the description. I also checked #1182 (open): in title_textures.rs it only adds one GPU test to the tests module, and it edits vram.rs and kernelx.rs, so it does not touch this code. Listed too.
  • Point 3 and 4 need no change (existing behaviour, already in Not tested).

Tested: cargo test -p xcl --lib d3d12x::title_textures -- --test-threads=4: 14 passed, 1 failed, 1 ignored. The failure is placed_title_textures_share_vram_and_preserve_pixels (subresource 2 mismatch), which fails the same way on 3d5e3b1 (13 passed, 1 failed, 1 ignored). cargo clippy -p xcl --lib --tests: no warning on the changed lines. Update: xcl-smoke blocks for the new head 7d92772 and for main 384f7f7 are now in the description (1048 and 962 frames, no device removal or crash; other work ran on the PC, so not a timing comparison). The whole workspace was not run again for this commit.

AI-assisted: this follow-up was written and tested by Claude Code with Claude Sonnet 5.5.

**@⁠TG0000** on GitHub · 2026-11-24 13:58 UTC · [original](https://github.com/xcl-dev/xcl/pull/1086#issuecomment-7133639137) · edited 2026-11-24 16:45 UTC Thank you for the careful review. I checked each point against the code. Pushed `7d92772` on top of `3d5e3b1` (no force push): - Point 1: the `remapped` update moved into `Table::recheck_sources`, so it runs without a GPU. The new test `a_source_that_flips_keeps_the_sparse_selection_exact` has 26 textures, flips one source each way (and back, twice) and compares `collect_uploads` with `linear_upload_keys` after every flip. It also flips a shadowed texture. With the `remapped` update removed from the method, it fails. - Point 2: #1102 added to the overlap list in the description. I also checked #1182 (open): in `title_textures.rs` it only adds one GPU test to the tests module, and it edits `vram.rs` and `kernelx.rs`, so it does not touch this code. Listed too. - Point 3 and 4 need no change (existing behaviour, already in Not tested). Tested: `cargo test -p xcl --lib d3d12x::title_textures -- --test-threads=4`: 14 passed, 1 failed, 1 ignored. The failure is `placed_title_textures_share_vram_and_preserve_pixels` (subresource 2 mismatch), which fails the same way on `3d5e3b1` (13 passed, 1 failed, 1 ignored). `cargo clippy -p xcl --lib --tests`: no warning on the changed lines. Update: `xcl-smoke` blocks for the new head `7d92772` and for main `384f7f7` are now in the description (1048 and 962 frames, no device removal or crash; other work ran on the PC, so not a timing comparison). The whole workspace was not run again for this commit. AI-assisted: this follow-up was written and tested by Claude Code with Claude Sonnet 5.5.
Author
Owner

@⁠DavidM1911 on GitHub · 2026-11-25 08:36 UTC · original

Verification on RTX 3060 Ti (Windows 11), branch merged with current main:

  • cargo test -p xcl --lib: all passed, 0 failed, ~26 ignored. (Intermittent single-test flake / 0xc0000005 abort under parallel scheduling — tracked in #1978; clean on single-threaded rerun.)

Thanks!

**@⁠DavidM1911** on GitHub · 2026-11-25 08:36 UTC · [original](https://github.com/xcl-dev/xcl/pull/1086#issuecomment-7157254097) Verification on RTX 3060 Ti (Windows 11), branch merged with current `main`: - `cargo test -p xcl --lib`: all passed, 0 failed, ~26 ignored. (Intermittent single-test flake / 0xc0000005 abort under parallel scheduling — tracked in #1978; clean on single-threaded rerun.) Thanks!
Author
Owner

@⁠oni-swr on GitHub · 2026-11-25 18:33 UTC · original

RX 7800 XT (RDNA3, wave32/wave64) report on exact head 7d9277246277acb85a0a982a4a6b29ff1a1640d4 (as is, on its base 384f7f7f; no merge with current main, which merges cleanly).

Tested

  • AMD Radeon RX 7800 XT, driver 32.0.31035.1003; Ryzen 7 5700X3D; Windows 11 build 26200; Rust 1.100.0 MSVC; debug profile; dxc.exe from Windows SDK 10.0.26100.0.
  • cargo test --workspace --no-fail-fast -- --test-threads=4 on this head: 739 passed, 0 failed, 42 ignored (19 targets); lib: 696 passed, 0 failed, 22 ignored.
  • Baseline, same machine and command, unmodified main at c9ee916a: 1330 passed, 2 failed, 46 ignored (24 targets). The 2 failures are gpu::dxil::fuzz_tests::fuzz_validate_and_gpu_1 (seed 722: CPU 0x7fffffff, GPU 0x1) and gpu::recomp::lower_dxil::tests::a_bridged_mask_write_where_one_half_is_elsewhere_meets_no_barrier.
  • Note: this older head does not contain either of the two baseline-failing tests (grep finds no fuzz_validate_and_gpu_1 in its output), so the 0 failures here say nothing about them.
  • Relevant tests, all passing: hle::d3d12x::title_textures::tests::* (including a_lazily_mapped_page_in_a_gpu_view_is_its_own_source, a_source_that_flips_keeps_the_sparse_selection_exact)
  • SKIPPED: none printed on this older head (the f16 and heap-window tests that skip on main are not in its output).

Not tested

  • No title and no scripts/smoke.ps1 run (no xcl-smoke blocks): I did not run an untrusted retail executable. This is a test-suite report only, not the regression run the PR needs.
  • Release profile, NVIDIA, Intel, Wine, RDNA2/RDNA4.

AI use

  • This run and report were done by Claude Code (Claude Sonnet 5.5): it fetched the head, ran the commands above and wrote this comment. Nothing was reviewed line by line for correctness here.
**@⁠oni-swr** on GitHub · 2026-11-25 18:33 UTC · [original](https://github.com/xcl-dev/xcl/pull/1086#issuecomment-7171080295) **RX 7800 XT (RDNA3, wave32/wave64) report on exact head `7d9277246277acb85a0a982a4a6b29ff1a1640d4`** (as is, on its base `384f7f7f`; no merge with current `main`, which merges cleanly). **Tested** - AMD Radeon RX 7800 XT, driver 32.0.31035.1003; Ryzen 7 5700X3D; Windows 11 build 26200; Rust 1.100.0 MSVC; debug profile; `dxc.exe` from Windows SDK 10.0.26100.0. - `cargo test --workspace --no-fail-fast -- --test-threads=4` on this head: 739 passed, 0 failed, 42 ignored (19 targets); lib: 696 passed, 0 failed, 22 ignored. - Baseline, same machine and command, unmodified `main` at `c9ee916a`: 1330 passed, 2 failed, 46 ignored (24 targets). The 2 failures are `gpu::dxil::fuzz_tests::fuzz_validate_and_gpu_1` (seed 722: CPU `0x7fffffff`, GPU `0x1`) and `gpu::recomp::lower_dxil::tests::a_bridged_mask_write_where_one_half_is_elsewhere_meets_no_barrier`. - Note: this older head does not contain either of the two baseline-failing tests (grep finds no `fuzz_validate_and_gpu_1` in its output), so the 0 failures here say nothing about them. - Relevant tests, all passing: `hle::d3d12x::title_textures::tests::*` (including `a_lazily_mapped_page_in_a_gpu_view_is_its_own_source`, `a_source_that_flips_keeps_the_sparse_selection_exact`) - `SKIPPED`: none printed on this older head (the f16 and heap-window tests that skip on `main` are not in its output). **Not tested** - No title and no `scripts/smoke.ps1` run (no `xcl-smoke` blocks): I did not run an untrusted retail executable. This is a test-suite report only, not the regression run the PR needs. - Release profile, NVIDIA, Intel, Wine, RDNA2/RDNA4. **AI use** - This run and report were done by Claude Code (Claude Sonnet 5.5): it fetched the head, ran the commands above and wrote this comment. Nothing was reviewed line by line for correctness here.
This pull request can be merged automatically.
This branch is out-of-date with the base branch
You are not authorized to merge this pull request.
View command line instructions

Checkout

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

Merge

Merge the changes and update on Forgejo.
git switch 'main'
git merge --no-ff 'github-bot/gh-1086'
git switch 'github-bot/gh-1086'
git rebase 'main'
git switch 'main'
git merge --ff-only 'github-bot/gh-1086'
git switch 'github-bot/gh-1086'
git rebase 'main'
git switch 'main'
git merge --no-ff 'github-bot/gh-1086'
git switch 'main'
git merge --squash 'github-bot/gh-1086'
git switch 'main'
git merge --ff-only 'github-bot/gh-1086'
git switch 'main'
git merge 'github-bot/gh-1086'
git push origin 'main'
This discussion has been locked. Commenting is limited to contributors.
No description provided.