Compile the replay merge helper through the shared compiler and test its output #1085

Manually merged
github merged 1 commit from github-bot/gh-1085 into main 2026-11-29 08:22:23 +00:00 AGit
Owner

@⁠ghptc on GitHub · 2026-11-28 13:00 UTC · original
ghptc:fix/replay-merge-compiler → main · +58 −37 · 1 files · 1 commits · merged 2026-11-29 08:16 UTC

The diagnostics replay merger calls D3DCompile directly and discards its diagnostic output. Its cs_5_1 shader reads a RWByteAddressBuffer. On Proton Experimental's built-in compiler this produces E5005 for Load and returns E_FAIL before pipeline creation. The same HLSL compiles with Microsoft's D3DCompiler_47.

Build the merge pipeline through the existing host compiler, attach the operation name to compilation failures, and use the same pipeline constructor in a small hardware regression. The shader, binding order and merge rules stay intact. The test dispatches one group over four synthetic words, waits for the queue and checks all three output buffers. It requires the diagnostics feature and an explicitly selected test run on a D3D12-capable host.

cargo test --release --locked -p victory-gpu --features diagnostics --lib replay::play::merge::tests::merge_preserves_gpu_writes_and_counts_cpu_changes -- --exact --ignored

On an RTX 5070 under VKD3D-Proton, the isolated main-based branch passed using Microsoft FXC. The destination was [2,6,7,9], the comparison base was [2,5,6,9] and the counters were [1,2,1,0]. The local build combining this change with #925 produced the same three arrays using Proton's built-in compiler and the app-local DXC fallback. Current main's shared compiler still uses D3DCompile alone. The Linux fallback result depends on #925 or an equivalent shared compiler implementation. This patch adds the missing replay consumer and a test and can be reviewed separately. The measurements used a Windows-target release build under Proton.

**@⁠ghptc** on GitHub · 2026-11-28 13:00 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/1085) `ghptc:fix/replay-merge-compiler` → `main` · +58 −37 · 1 files · 1 commits · merged 2026-11-29 08:16 UTC The diagnostics replay merger calls D3DCompile directly and discards its diagnostic output. Its cs_5_1 shader reads a RWByteAddressBuffer. On Proton Experimental's built-in compiler this produces E5005 for Load and returns E_FAIL before pipeline creation. The same HLSL compiles with Microsoft's D3DCompiler_47. Build the merge pipeline through the existing host compiler, attach the operation name to compilation failures, and use the same pipeline constructor in a small hardware regression. The shader, binding order and merge rules stay intact. The test dispatches one group over four synthetic words, waits for the queue and checks all three output buffers. It requires the diagnostics feature and an explicitly selected test run on a D3D12-capable host. ```text cargo test --release --locked -p victory-gpu --features diagnostics --lib replay::play::merge::tests::merge_preserves_gpu_writes_and_counts_cpu_changes -- --exact --ignored ``` On an RTX 5070 under VKD3D-Proton, the isolated main-based branch passed using Microsoft FXC. The destination was [2,6,7,9], the comparison base was [2,5,6,9] and the counters were [1,2,1,0]. The local build combining this change with #925 produced the same three arrays using Proton's built-in compiler and the app-local DXC fallback. Current main's shared compiler still uses D3DCompile alone. The Linux fallback result depends on #925 or an equivalent shared compiler implementation. This patch adds the missing replay consumer and a test and can be reviewed separately. The measurements used a Windows-target release build under Proton.
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-28 14:32:45 +00:00
Author
Owner

@⁠ghptc on GitHub · 2026-11-28 13:23 UTC · original

Windows Clippy reported the same two diagnostics on this PR and its exact upstream base, 63b902f: let_and_return in shader emission and manual_is_multiple_of in the shadow worker. With #957 applied locally to 2deacb8, both locked workspace Clippy checks passed for Windows MSVC on Rust 1.98.1, including --all-features, with -D warnings. Upstream CI log

**@⁠ghptc** on GitHub · 2026-11-28 13:23 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/1085#issuecomment-7239896247) Windows Clippy reported the same two diagnostics on this PR and its exact upstream base, `63b902f`: `let_and_return` in shader emission and `manual_is_multiple_of` in the shadow worker. With #957 applied locally to `2deacb8`, both locked workspace Clippy checks passed for Windows MSVC on Rust 1.98.1, including `--all-features`, with `-D warnings`. [Upstream CI log](https://github.com/trustno1-coder/VIctory-NVIDIA/actions/runs/46104876336/job/140855261577)
github manually merged commit 9867c077ec into main 2026-11-29 08:22:23 +00:00
This discussion has been locked. Commenting is limited to contributors.
No reviewers
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
github/trustno1-coder--VIctory-NVIDIA!1085
No description provided.