Repository navigation
Conversation
The console command list's RSSetShadingRate sits at xcl-dev#124 on the base layout (previously remapped straight to PC xcl-dev#77) and at xcl-dev#126 on the newer layout, which was unrouted and fell into the console-extension stub. Route both through list_x::rs_set_shading_rate_x: without variable-rate shading on the host (D3D12_FEATURE_D3D12_OPTIONS6, probed once at device creation and cached) a clean no-op, otherwise a sanitized forward to ID3D12GraphicsCommandList5::RSSetShadingRate. Unsupported rate axes are clamped to what the adapter supports and unknown combiner values act as PASSTHROUGH (the D3D12 ApplyCombiner default arm); an unreadable combiners pointer is treated as NULL (the PC defaults). The rate is recorded with the other Reset-cleared state and re-applied after KickoffX and a deferred mid-list split. Assisted-by: ZCode (GLM-5.4)
|
Full-suite run, since this PR has no test report yet. Tested exact head Tested
Not tested
AI use
|
|
Code review on
Remaining before merge: |
|
Linux (Wine + vkd3d-proton) + NVIDIA test of Setup: Fedora 44 (kernel 7.2.9), Wine 11.21 Staging, vkd3d-proton v3.1-90-g30b0eb9b, RTX 4070 12 GB (driver 615.71.09), Ryzen 9 9950X3D, 62 GB RAM; release, cross-compiled to Tested
Read
Not tested: that each call reaches the PC's AI use: Claude Code (Claude Fable 5.2) read the diff, built the trees, ran the title and the tests, compared the frames and wrote this comment. Posted without review by a person: the account owner was away and reads replies later. |
|
Verification on RTX 3060 Ti (Windows 11), branch merged with current
Thanks! |
PR #1944 compatibility verificationCommit Tested
Not tested Live CL5 shading-rate forwarding and restoration after command-list splits, the VRS-unsupported path on hardware, and other adapters. No retail-title smoke run or AI use T3 Code / Codex ( |
The console command list's
RSSetShadingRatesits at#124on the base console layout and at#126on the newer layout.mainalready remapped the base slot straight to the PC'sID3D12GraphicsCommandList5::RSSetShadingRate(PC#77), while the newer slot#126was unrouted and fell into the console-extension stub (ID3D12GraphicsCommandList10::#126 (not on PC)). Both slots now route through a single capability-gated handler. Part of #505.What is in it
crates/xcl/src/hle/d3d12x/device_x.rs: probe and cacheD3D12_FEATURE_DATA_D3D12_OPTIONS6(VariableShadingRateTier,AdditionalShadingRatesSupported) on the underlying PCID3D12Deviceat creation and log it once (probe_vrs,vrs).crates/xcl/src/hle/d3d12x/list_x.rs: addrs_set_shading_rate_x— clean no-op without host VRS; otherwise sanitize the base rate (clamp unsupported axes to 2X/4X perAdditionalShadingRatesSupported) and combiners (unknown combiners ->PASSTHROUGH, unreadablecombinerspointer ->NULLdefaults) before forwarding toID3D12GraphicsCommandList5::RSSetShadingRate, and record/re-apply the state acrossKickoffXand mid-list splits (restore_bindings).crates/xcl/src/hle/d3d12x/real.rs: route console#124throughrs_set_shading_rate_xinstead of the bare PC remap and map newer-layout#126to#124inNEWER_LIST_SLOTS(title_listwrappers inherit this through the extended vtable).device_x.rs/list_x.rs/real.rs): slot-routing table assertions, rate/combiner sanitization unit tests, null-list no-op test, and an isolated child-process D3D12 debug-layer forwarding test.Tested
32.0.15.9144), AMD Ryzen 5 7500F 6-Core Processor, Windows 11 Pro x64 (build 26200),rustc 1.100.0 (0ef1bc386 2026-11-09); debug and releasecargo test --workspace --no-fail-fast -- --test-threads=4: 979 passed, 1 failed, 45 ignored (xcl --lib: 930 passed, 1 failed, 25 ignored; 16xclintegration targets: 49 passed, 0 failed, 20 ignored;xclbin /xcl-testtitle/ doc-tests: 0 tests). SKIPPED GPU tests: 21 ingpu::recomp(no wave64/ unsupported wave32 per-laneV_MUL_F16,V_PK_MUL_F16,V_CVT_F16_F32), 1 inshaders::tests::pso_measurement_compiles_an_exact_synthetic_record(Windows Developer Mode required to disable driver cache), and 1 ingpu_compute_e2e::heap_window_out_of_memory_falls_back_to_the_switch_form(no heap windows). The single failure (gpu::recomp::tests::gpu_clamp_and_omod_per_instruction,v_pk_add_i16clamp) is pre-existing onmainon this GPU/driver.cargo test -p xcl --test '*' -- --test-threads=4: 49 passed, 0 failed, 20 ignored (1 SKIPPED:heap_window_out_of_memory_falls_back_to_the_switch_form: no heap windows)title: 3c290c16, 60 s releasescripts/smoke.ps1):main(689f2db) logged[STUB] d3d12_xs.dll!ID3D12GraphicsCommandList10::#126 (not on PC)(1061frames);30862adloggedD3D12.X: variable shading rate (OPTIONS6): tier 2, additional rates true, cleared the#126stub warning, and reached1099frames with 0 crashes / 0 device removals.Regression run
main:
PR:
Not tested
SV_ShadingRatereadback draw) from the forwarded shading rate#126identity on other titles: Glyph-cache menu text loses letters; black blocks on the brightness HUD (newer retail title) #1049 decodes#126as a stencil-ref setter on another runtime; while a title passes zeroed arguments this sanitized forward acts as default rate/combiners (flagged for review)RSSetShadingRateImage(console#125/ newer#127) is out of scopeAI use
GLM-5.4): wrote the implementation and unit/GPU tests in30862adand ran thexcl-smokeruns.Gemini 4 Hydrogen): verified the full workspace test suite, reviewed the diff and retail title run logs, validated the PR description withscripts/pr_check.py, and finalized this PR description.