VS / PS: the 32-lane form on every GPU that can run 32-lane waves (RD… #155
No reviewers
Labels
No labels
accessibility
bug
documentation
duplicate
enhancement
goal:world-load
good first issue
help wanted
invalid
keep-open
off-goal
question
stale
test-only
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/xcl-dev--xcl!155
Loading…
Reference in a new issue
No description provided.
Delete branch "gh-pr/155/head"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
@WarmMilkCodes on GitHub · 2026-11-23 17:17 UTC · original
WarmMilkCodes:rdna2-ps-wave32→main· +90 −25 · 7 files · 1 commits · merged 2026-11-23 20:51 UTCOn an RX 6600 XT (discrete RDNA2, reports 32–64 lanes) the driver runs wave64 pixel shaders in 32-lane waves, so
gpu_wave64_ps_whole_wave_reductionsfailed:wave32_only()is false for a 32–64 range, VS / PS did not get theupper_lanesform, andv_readlane32 wrapped to lane 0 (the sum doubled: 928 vs 464). Details in #42.Change:
pso::graphics_wave32(the adapter's range includes 32) now decides the split flag for VS / PS:real.rs: plain VS+PS pipelines, and the PS of mesh and GS pipelinesrunner::split_for,on_gpu) and the spill-slot tests' expectationsxcl shaders --precompile, so its cache keys match the runtime'sCompute, mesh and geometry programs keep
wave32_only(they set[WaveSize(64)]). Theupper_lanesform checksxcl_hw32at run time, so a driver that picks 64 lanes runs the program as before. On RDNA GPUs, wave64 VS / PS with constant or slot reads now get the 32-lane form's HLSL; 64-lane-only GPUs are unchanged. Doc:docs/wave64-on-wave32.md.Tested: RX 6600 XT, driver 32.0.21045.29003, Windows 11 23H2:
cargo test --workspace: 568 passed, 0 failed (before:gpu_wave64_ps_whole_wave_reductionsfailed; it passed only withXCL_SPLIT_WAVE64=1). Not tested on RDNA4 or NVIDIA.🤖 Generated with Claude Code
@Vencite on GitHub · 2026-11-23 18:53 UTC · original
tested this on my rtx 4080 super (driver 621.24).
built main (
956a476bf7) and the pr (fc4b2d48f1) separately and ran the same tests on both, with XCL_SPLIT_WAVE64 unset.all three wave64 gpu tests passed on both builds (ps reductions, ps spill slots, vs spill slots/identity). the reduction test reported 32-lane waves in both cases, and the wave path selection unit test passed too.
so far no regressions on my nvidia setup, at least in these tests. can't say anything about the original rx 6600 xt issue though.
@TheHoracio on GitHub · 2026-11-23 19:13 UTC · original
Tested on RDNA3: AMD Radeon RX 7800 XT (16 GB, reports 32–64 lanes), driver 32.0.32015.7029, Windows 11 Pro 10.0.26300, Rust 1.100.0, DXC 1.9.2602.17 (SDK 10.0.26100.0).
The RX 6600 XT failure reproduces on RDNA3 and this PR fixes it:
XCL_SPLIT_WAVE64gpu_wave64_ps_whole_wave_reductionsmain956a476left: [2, 928, 2],right: [2, 464, 2](same doubled sum as the 6600 XT)main956a4761fc4b2d4fc4b2d4XCL_REQUIRE_GPU=wave64,meshSKIPPEDgpu_wave64_ps_spill_slots,gpu_wave64_vs_spill_slots_and_identity,geometry_wave_path_selection_preserves_native_wave64andupper_lanes::spill_slots_come_from_their_shadowpass in all four runs.* The remaining failure is
test_title_runs_and_game_folder_is_untouched(e2e.rs:123). It is the false failure from #42: this machine has no Gaming Services, so preflight printsWARNING: no System32\xgameruntime.dll. The test title itself ran tofailures: 0. That failure is unrelated to this PR (fixed in #180).So on RDNA3, as on RDNA2, the driver runs wave64 pixel shaders in 32-lane waves. Gating the VS / PS form on
graphics_wave32looks right for RX 7000 too.@CodeByCon on GitHub · 2026-11-23 19:14 UTC · original
tested this on my rx 7800 xt (driver 32.0.32029.2010, windows 11 build 26300.9974) and can confirm the same failure: 928 vs 464 on main (
956a476), twice. with XCL_SPLIT_WAVE64=1 the test passes.@WarmMilkCodes on GitHub · 2026-11-23 19:22 UTC · original
Thanks @Vencite, @TheHoracio and @CodeByCon for testing. Summary so far:
main956a476gpu_wave64_ps_whole_wave_reductionsfails (928 vs 464)So RDNA2 and RDNA3 both run wave64 PS in 32-lane waves despite reporting 32–64; the fix applies there and leaves NVIDIA unchanged. Still rebased on current
main.@ivall on GitHub · 2026-11-23 20:52 UTC · original
Merged (main
2abc562). The conflict with lazy pipeline creation, now on main, was resolved: thepso_async::lazydefer check stays first, thengraphics_wave32picks the split form. Checked on an RX 9070 (RDNA4) with the 11 PRs merged together on main38b05b7:cargo build --workspace && cargo test --workspace -- --test-threads=4- 547 unit tests passed, 0 failed (19 ignored); the integration and e2e tests passed too.