Repository navigation
Conversation
|
Ran the new uniform tests on an NVIDIA Blackwell part at Environment: Windows 11 Pro build 26200 x64, NVIDIA GeForce RTX 5070 Ti (Blackwell, wave32 only, 16 GB) driver 32.0.16.2124, Intel Core i5-12400F, 64 GB RAM, rustc 1.100.0 (0ef1bc386 2026-11-09) MSVC 14.44.35207, DXC 1.9.2609.5, debug build. All six split-wave64 GPU tests pass here, including the new Not tested: native wave64 (not available here), RDNA2/RDNA4 and Intel GPUs, Wine, release profile, retail titles. AI-assisted (OpenCode), model: DeepSeek V4.1 Flash 1017 - checked out the PR's head commit in a detached worktree, built it, ran the tests, wrote this report; the worktree was not modified. |
|
Ran the PR on NVIDIA Ampere (wave32 only, so split wave64 is the path in use) at head Tested
Not tested
AI use
|
|
Independent verification on current Machine: Windows 11, Ryzen 9 7900X + RTX 3060 Ti; Rust stable MSVC, debug; DXC 1.8.2502.11.
AI use: test runs by Devin (Cognition, SWE-2); no code changes. |
Test report on NVIDIA GeForce RTX 2070 SUPER (Turing, wave32)Commit tested Tested
Not tested
AI use
|
|
A run on Linux with vkd3d-proton, where the shaders go through dxil-spirv to Vulkan instead of a Windows driver's DXIL compiler. Tested
Not tested
AI use
|
|
Counter-datapoint from the axis every report above skips: native wave64 hardware (AMD RDNA3) with the split path forced. All five runs so far are NVIDIA wave32 parts where split-wave64 emulation is the only path; here it has to coexist with real 64-lane waves, so I ran it with Lane:
Net on this axis: strictly worse - two tests that pass on the control go red, none go green, and the PR's own test fails its numeric assert. Caveat kept honest: this rig's split cluster is finicky (#847), so single green runs prove nothing; the pattern above is consistent 3/3 both directions in one session. Happy to re-check a future head with the same 3x fix-vs-control combo. Machine: RX 7900 XT (RADV NAVI31), Mesa 26.2.5, kernel 7.2 (Arch), Proton Experimental (wine-11.0), patched vkd3d-proton v3.1, Rust cross AI use: Hermes agent (local Qwen-class) ran the suite and drafted this; I checked it before posting. |
|
Thanks for testing the forced-split RDNA3/RADV path — super useful catch on the test assertion! Regarding
I pushed AI use: Antigravity (Gemini 4 Neon) analyzed the |
|
Verified head
Not tested: AMD native wave64, full workspace, retail smoke ( |
|
Tested on NVIDIA Blackwell: head
Speed, since no report has timings yet. A local benchmark (not for a PR, built like
About 9x faster in the uniform case, the same for 64- and 256-thread groups, and no change where the value is Not tested
AI use
|
|
AMD side of the new head Same rig and forced split mode (
Counts only, no game data. Machine: RX 7900 XT (RADV NAVI31), Mesa 26.2.5, kernel 7.2 (Arch), Proton Experimental (wine-11.0), patched vkd3d-proton v3.1, Rust cross AI use: Hermes agent (local Qwen-class) ran the suite and drafted this; I checked it before posting. |
7c16823 to
5ae60ad
Compare
TestedPR #1193 was open at STOR-WINLAB ran Windows 11 Enterprise Evaluation 25H2 x64 build cargo test --locked -p xcl --lib --no-run --message-format=json-render-diagnostics
& 'L:/XclTooling/Invoke-ArcTest.ps1' -Test {
& 'L:/XclTooling/pr1975-b62e6e3/target/debug/build/xcl/97fdf2b9ff8e1482/out/xcl-97fdf2b9ff8e1482.exe' `
'gpu::recomp::tests::gpu_split_wave64_uniform_readfirstlane' --exact --test-threads=1 --nocapture
}The prebuild ran outside the Arc mutex, with The executable SHA-256 was 1 passed, 0 failed, 0 ignored, 0 GPU skips, 1,082 filtered out, 0.31 s, wrapper exit 0. The build completed with two Rust deprecation warnings. PowerShell formatted the fixture's DXC version message as
Not testedNative wave64, forced split on a native-wave64 adapter, Direct DXIL, other GPUs, other fixtures, the full workspace suite, retail smoke, and performance. AI useT3 Code / Codex ( |
|
Independent Windows run on 5ae60ad. Windows 11 build 26300, Ryzen 7 9800X3D, RTX 3080 Ti (621.35), Rust 1.99.1 MSVC, DXC 1.8.2502.11, debug.
For a separate synthetic check, LLVM MC 23.1.6 assembled a gfx1030 kernel with a branch on empty EXEC and a uniform float-add and conversion feeding
|
|
Diff review on Only item remaining before merge is a quick |
Reading a diff is safe; building one is not. `cargo build` runs a pull request's build.rs and procedural macros as the user, `cargo test` runs its test code, and anything under scripts/ runs as the user during build, test and the smoke run. So the decision to trust a branch has to be made before the first build, not after it. - scripts/dev/pr-gate.py classifies a pull request's changed files from the GitHub API only - no checkout, nothing executed - against eight high-risk buckets (build.rs, .github, .cargo, Cargo.toml/lock, scripts, generated tables, stubdb.toml, binaries) plus a short content scan of added lines for network fetches, base64/eval, process spawning, link-section tricks and credential access. Fail-closed: an API error exits 3, never 0. A CLEAR verdict writes a receipt keyed by the pull request's head commit, so a force-push has to pass the gate again. - scripts/dev/merge-pr.py is the only sanctioned merge path: gate, require a receipt for that exact commit, fetch pull/<N>/head, verify what arrived is what was reviewed (the window a push could otherwise slip through), then merge --no-ff. - scripts/dev/merge-guard.py, wired as a PreToolUse hook, refuses git merge, cherry-pick, pull without --ff-only, am, apply, revert and gh pr merge unless they go through the wrapper. Recovery and read-only forms stay allowed. - .githooks/pre-merge-commit backstops a merge made by hand, allowing commits already in our own history through. Verified on xcl-dev#1193 (clean: exit 0, fetch matched the reviewed commit), xcl-dev#282 (scripts/ touched: exit 2, nothing fetched), and xcl-dev#282 with --ack (exit 0, acknowledgement recorded in the receipt). merge-guard decided 13 command forms correctly. pre-merge-commit tested in a throwaway repo for own-history, no-receipt and receipted cases. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_018RbZXznytQeB5KoWdhtdy5
Test report: Windows AMD RX 7800 XT, forced split wave64, exact head
|
|
Re-verification on RTX 3060 Ti (Windows 11), new head merged with current
Thanks! — Devin |
Prime1997
left a comment
There was a problem hiding this comment.
Needs changes: exhausted shared loop budget can produce a false EXEC-nonzero proof. Exact PR head 5ae60ad0a9baefd8baa244f36f9e5712f83b37d4.
The runtime loop guard runs before a loop's first instruction, and its budget is shared across loops. x64_uniform::exec_nonzero adds guard-exit edges using only post-instruction facts. If an earlier loop exhausts the budget, a later loop beginning with s_mov_b64 exec, -1 is skipped. The analysis nevertheless propagates that nonzero EXEC fact past the second loop. A following predicated VGPR move must preserve the old value with EXEC zero, while the optimized readfirstlane can return its unconditional captured scalar instead.
Measured CPU regression: an isolated checkout with production code unchanged and one seven-instruction analysis fixture added produced 0 passed, 1 failed, 0 ignored, 0 skipped, at the false nonzero proof. The positive nonzero control ran before that assertion. Test-only source patch SHA-256: 642ab6d8895c86a270727dfb0f565707565204e1e7a5a0f898e6a61787db2a52.
A separate, uncommitted local repair makes guard-exit facts conservative over both pre- and post-instruction states, including the SCC relation. The identical regression plus all three original CPU analysis fixtures produced 4 passed, 0 failed, 0 ignored, 0 skipped. Repair source patch SHA-256: c51b1a9f9ad4547389f675ba3962945fab021d869d403ebdf5e4e1b55381d5fc. This repair is local and has not been pushed into the PR.
Exact filters:
gpu::recomp::x64_uniform::tests::exhausted_shared_loop_budget_does_not_prove_exec_nonzerogpu::recomp::x64_uniform::tests::scalar_div_chain_with_nonzero_exec_is_capturedgpu::recomp::x64_uniform::tests::cbranch_execz_and_saved_exec_restore_prove_exec_nonzerogpu::recomp::x64_uniform::tests::non_uniform_exec_maybe_zero_and_loop_exit_stay_conservative
Build each isolated worktree: cargo test --locked --offline -p xcl --lib --no-run --message-format=json --target-dir <isolated-target>. Run each filter in a fresh process: <test-exe> <exact-filter> --exact --test-threads=1 --nocapture. Windows 11 Pro26200, i5-10400, 32GiB, Rust1.100.0 MSVC debug; private paths are placeholders.
Not tested: no shader loop was dispatched, no DXC/device call occurs in these finite analysis fixtures, and no GPU/title correctness or whole-suite result is claimed. Latest main b49be1836844fe0b0cdb3211dce3cb7fb4e21ac7 has the same shared guard but not this optimization; the local repair was tested on the PR head, not a rebased integration. Source locations: x64_uniform.rs:115–120,147–149; mod.rs:638,1017,1138; emit.rs:6077.
AI use: Codex (GPT-6) reviewed the source and checked the stated evidence. Optional temporary Discord for coordinating contributor work, testing and comparing results.
|
merge-check claim |
|
merge-check |
|
#900 also targets split wave64, but it makes the half / console wave / other-half size wave-uniform through WaveReadLaneFirst at entry; this PR instead skips the v_readfirstlane_b32 exchange for VGPR chains computed from uniform operands. #944 / #2343 batch exchanges rather than remove them. None makes the same change, and main has no AI review: Claude Code (Claude Opus 5.5), diffs read only, not built or run; not checked by a human. |
��Eliminates split-wave64
xcl_x_rla_uniform()(xcl_x_meet()) cross-half exchanges forv_readfirstlane_b32when the source VGPR holds a wave-uniform value under guaranteedEXEC != 0.Why
udivchains (v_cvt_f32_u32�!v_rcp_iflag_f32�!v_mul_legacy_f32�!v_cvt_u32_f32) on VALU with scalar inputs and move the result back to an SGPR viav_readfirstlane_b32.docs/wave64-on-wave32.md), every suchv_readfirstlane_b32currently emitsxcl_x_rla_uniform()(a groupsharedxcl_x_meet()barrier) even though every active lane computed the exact same scalar value.EXEC != 0is statically guaranteed (sofirst_lane(exec)always selects an active lane, never falling back to inactive lane 0) and the source VGPR was produced in the same basic block (with unchangedEXEC) by a chain of plain, full-32-bit-overwrite, lane-independent VALU ops over uniform inputs, we capture each producer in that chain into an immutable scalar temporary (uint tN = ...;) evaluated from uniform operands. Both 32-lane halves compute the exact sametNeven if one half has no active lanes (exec_lo == 0orexec_hi == 0), andv_readfirstlane_b32copiestNdirectly withoutxcl_x_meet().What is in it
crates/xcl/src/gpu/recomp/x64_uniform.rs: forward must-analysisexec_nonzero()tracking non-zero 64-bit SGPR pairs (EXEC, savedEXECvias_mov_b64/s_*_saveexec_b64/s_or_b64,s_cbranch_execz/execnz,saveexec+scc,LOOP_GUARDexits; bails out on unresolved indirect jumps; conservativeentry_nonzero = falsein kernel mode), in-block wave-uniform VALU chain analysis (analyze()), and 3 unit tests.crates/xcl/src/gpu/recomp/mod.rs: runx64_uniform::analyzein split-wave64 mode for Kernel / Compute / Mesh.crates/xcl/src/gpu/recomp/emit.rs: capture uniform temporaries only for PCs inx64_uniform.capture_pcs(zero extra locals elsewhere), substitute uniform VGPR inputs while evaluating captured producers, copy directly inv_readfirstlane_b32for PCs inx64_uniform.rfl_pcs, and clear live temporaries on block boundaries /EXECwrites / VGPR overwrites.crates/xcl/src/gpu/recomp/tests.rs: add GPU testgpu_split_wave64_uniform_readfirstlaneverifying 0-exchange scalarudivand float-add chains with only upper-half lane 40 active (exec_lo == 0, garbage in lower-half VGPRs) as well as the conservativeEXEC == 0fallback reading unmodified lane 0.Measured impact (RTX 3060 Ti, split-wave64)
xcl_x_rla_uniform()calls drop from 80,310 �! 64,658 (�"15,652 exchanges, �"19.5%).cs_6_6) and NVIDIA D3D12 PSO compile benchmarks on three retail compute shaders (before47efa2e�! after0d8bcd5):xcl_x_rla_uniform57 �! 12(�"78.9%), DXIL57,328 �! 41,168 B(�"28.2%), DXC347.8 �! 239.7 ms(�"31.1%), cold PSO323.6 �! 218.7 ms(�"32.4%).xcl_x_rla_uniform505 �! 463(�"8.3%), DXIL1,200,072 �! 1,179,728 B(�"1.7%), DXC26,612 �! 24,784 ms(�"6.9%), cold PSO28,313 �! 29,146 ms(noise within 3%).xcl_x_rla_uniform43 �! 13(�"69.8%), DXIL144,708 �! 133,000 B(�"8.1%), DXC1,343 �! 1,148 ms(�"14.6%), cold PSO1,859 �! 1,696 ms(�"8.8%).Tested
x86_64-pc-windows-msvc), debug + release.cargo test -p xcl --lib x64_uniform -- --test-threads=1: 3 passed, 0 failed.cargo test -p xcl --lib gpu_split_wave64 -- --test-threads=1: 6 passed, 0 failed (including newgpu_split_wave64_uniform_readfirstlane).cargo test --workspace -- --test-threads=1: 745 passed, 0 failed, 41 ignored (1 SKIPPED GPU test:gpu::recomp::tests::gpu_wave32_program_in_wave64_hardware(no wave64)).Regression run
main:
PR:
Not tested
x64_uniformonly runs whensplit_wave64is active on wave32-only GPUs or forced viaXCL_SPLIT_WAVE64=1).AI use
v_readfirstlane_b32producers across the shader corpus, designed and implementedx64_uniform.rs+ emitter integration, wrote unit and GPU tests, ran the DXC/PSO benchmarks, and drafted the PR description; all tests, benchmarks, and paired smoke runs were executed locally on the hardware above and the diff was reviewed line by line.