Repository navigation
D3D12.X: default DepthEnable to false in stream_pipeline when DSVFormat is UNKNOWN - #1772
Conversation
…at is UNKNOWN In eal::stream_pipeline, DepthStencilState.DepthEnable was unconditionally initialized to rue, even when a D3D12_PIPELINE_STATE_STREAM_DESC omitted DEPTH_STENCIL / DEPTH_STENCIL1 / DEPTH_STENCIL2 and had DSVFormat == DXGI_FORMAT_UNKNOWN (0). Per D3D12 pipeline state stream rules, default DepthEnable to alse when no depth-stencil subobject is provided and DSVFormat == DXGI_FORMAT_UNKNOWN, while keeping DepthEnable = true when a non-UNKNOWN DSVFormat is present and always honoring explicit depth-stencil subobjects. Part of xcl-dev#1488 (XCL-BT-034). Assisted-by: Antigravity (Gemini 4 Neon)
…at is UNKNOWN (xcl-dev#1772) Fixes real::stream_pipeline so DepthStencilState.DepthEnable defaults to false when a D3D12_PIPELINE_STATE_STREAM_DESC omits the DEPTH_STENCIL / DEPTH_STENCIL1 / DEPTH_STENCIL2 subobject and DSVFormat is DXGI_FORMAT_UNKNOWN (0). Addresses tracking issue xcl-dev#1488 (finding XCL-BT-034). Resolves stream pipeline creation failures (hr=0x80004005) when creating graphics pipelines with no bound depth-stencil view. (by AlpPesen) Assisted-by: Antigravity
|
NVIDIA test report for Tested
Regression run ( base ( this PR: Not tested: a title that creates stream pipelines without a depth-stencil subobject (I don't know whether this one does at its start screen); AMD on Windows; Wine on NVIDIA. AI use: Claude Code (Claude Opus 5.5) built and ran the tests and smoke runs on my machine and wrote this report; I checked it. |
|
Verification on RTX 3060 Ti (Windows 11), branch merged with current
Thanks! |
, xcl-dev#1910) Brings main to full parity with upstream/main (6567c5f): - xcl-dev#1937: declare triangle topology for translated mesh PSOs - xcl-dev#1772: default DepthEnable to false in stream_pipeline when DSVFormat is UNKNOWN - xcl-dev#1910: take native compute mask branches across the whole wave Assisted-by: Antigravity (Gemini 4)
Fixes
real::stream_pipelinesoDepthStencilState.DepthEnabledefaults tofalsewhen aD3D12_PIPELINE_STATE_STREAM_DESComits theDEPTH_STENCIL/DEPTH_STENCIL1/DEPTH_STENCIL2subobject andDSVFormatisDXGI_FORMAT_UNKNOWN(0).Previously
stream_pipelineunconditionally initializedDepthEnable = true, violating D3D12 pipeline state stream defaults for graphics streams that neither bind a depth-stencil view nor supply a depth-stencil subobject.Part of #1488 (
XCL-BT-034).What is in it
crates/xcl/src/hle/d3d12x/real.rs:11,21,26) was present instream_pipeline.g.DepthStencilState.DepthEnable = false.into()when!has_depth_stencil && g.DSVFormat.0 == 0(DXGI_FORMAT_UNKNOWN). Streams with a non-UNKNOWNDSVFormatcontinue to defaultDepthEnable = true, and explicit depth-stencil subobjects are always preserved.stream_pipeline_defaults_depth_enable_from_dsv_formatcovering omitted/UNKNOWNDSVFormat, non-UNKNOWNDSVFormat, and explicitDEPTH_STENCILsubobjects.Regression run
Baseline (immediate parent
mainb9b6ea6, warm shader/PSO cache):This PR (
fix/stream-pipeline-depth-default, warm shader/PSO cache):Tested
Hardware: Windows 11 Pro for Workstations (Build 26300), Intel Core i9-9900K, 32 GB RAM, AMD Radeon RX 6800 (16337 MiB VRAM, Driver
32.0.21045.29003),rustc 1.100.0 (0ef1bc386 2026-11-09).cargo test -p xcl --lib stream_pipeline_defaults_depth_enable_from_dsv_format:1 passed; 0 failed; 0 ignored; 0 skipped.XCL_REQUIRE_GPU=wave64,mesh cargo build --workspace && cargo test --workspace --no-fail-fast -- --test-threads=4:885 passed; 5 failed; 42 ignored; 0 skipped(3 pre-existing RDNA2placed_title_textures_share_vram_and_preserve_pixels+VRAM_TEST_LOCKcascades tracked in D3D12.X: map a one-slice title texture's packed mips where D3D12 addresses them #470, plus 2 unrelated skip-gated tests that fail whenXCL_REQUIRE_GPUis set:pso_measurement_compiles_an_exact_synthetic_recordneeding Windows Developer Mode andheap_window_out_of_memory_falls_back_to_the_switch_formneedingXCL_HEAP_WINDOWS=1)..\scripts\smoke.ps1 -Game '<game folder>\YouKnowWho'onb9b6ea62080cc62fc19e212033372d01c6214e5candfa567957075adedf382f0d2d9ef9d967ea3b914e(see Regression run above).Not tested
AI use
Antigravity (Gemini 4 Neon) implemented the
DepthEnabledefault check and unit test incrates/xcl/src/hle/d3d12x/real.rs, and ran the full test suite and paired smoke runs.