d3d12-gpu: drop unused SM 6.6 root signature flags in depth_bounds test #2855
Open
lixonik wants to merge 3 commits from
upstream-pr/2855 into main
pull from: upstream-pr/2855
merge into: ProjectLeonida:main
ProjectLeonida:main
ProjectLeonida:claude/loop-total
ProjectLeonida:claude/pops-collision-seed
ProjectLeonida:claude/dstorage-hold-page-reads
ProjectLeonida:claude/host-image-copy-switch
ProjectLeonida:feat/gdk-lifecycle-window-hook
ProjectLeonida:claude/d16s8-uav-nvidia-fallback
ProjectLeonida:feat/mfplat-offline-shim
ProjectLeonida:claude/gameinput-slow-reader
ProjectLeonida:fix/rt-null-barrier-clear
ProjectLeonida:claude/depth-resolve-sample-positions
ProjectLeonida:integration/palmetto-parity
ProjectLeonida:claude/valu-literal-sext
ProjectLeonida:claude/slot74-pool-handle
ProjectLeonida:claude/rgb9e5-uint-alias-view
ProjectLeonida:claude/fssm-root-layout-tables
ProjectLeonida:feat/gdk-speech-display-lifecycle
ProjectLeonida:asset-audio-skip-current
ProjectLeonida:qemmhd/old-9940-rectangle-quad-lists
ProjectLeonida:feat/ws2-offline-shim
ProjectLeonida:qemmhd/rt-d16-unorm-uav
ProjectLeonida:feat/xs-device-stops-7-9
ProjectLeonida:qemmhd/rt-depth-same-base-shapes
ProjectLeonida:qemmhd/rt-lazy-attachment-variant
ProjectLeonida:feat/acphal-xma2-decoder
ProjectLeonida:asset-audio-skip
ProjectLeonida:codex/coord-claim-check-20261124-7e48
ProjectLeonida:feat/xs-frame-pacing-presentx
ProjectLeonida:feat/xs-device-vm-options
ProjectLeonida:old-pr/9844
ProjectLeonida:old-pr/9978
ProjectLeonida:old-pr/9815
ProjectLeonida:old-pr/10057
ProjectLeonida:old-pr/9874
ProjectLeonida:old-pr/9965
ProjectLeonida:old-pr/9863
ProjectLeonida:old-pr/10068
ProjectLeonida:old-pr/10066
ProjectLeonida:old-pr/10067
ProjectLeonida:old-pr/10007
ProjectLeonida:old-pr/10061
ProjectLeonida:old-pr/10065
ProjectLeonida:old-pr/10059
ProjectLeonida:old-pr/10063
ProjectLeonida:old-pr/10055
ProjectLeonida:old-pr/10062
ProjectLeonida:old-pr/10042
ProjectLeonida:old-pr/10041
ProjectLeonida:old-pr/10049
ProjectLeonida:old-pr/10047
ProjectLeonida:old-pr/10046
ProjectLeonida:old-pr/10045
ProjectLeonida:old-pr/10056
ProjectLeonida:old-pr/10043
ProjectLeonida:old-pr/10036
ProjectLeonida:old-pr/10034
ProjectLeonida:old-pr/9984
ProjectLeonida:old-pr/10052
ProjectLeonida:old-pr/10038
ProjectLeonida:old-pr/10033
ProjectLeonida:old-pr/10028
ProjectLeonida:old-pr/10050
ProjectLeonida:old-pr/9891
ProjectLeonida:old-pr/9889
ProjectLeonida:old-pr/10051
ProjectLeonida:old-pr/10019
ProjectLeonida:old-pr/10027
ProjectLeonida:old-pr/10029
ProjectLeonida:old-pr/10031
ProjectLeonida:old-pr/10026
ProjectLeonida:old-pr/9941
ProjectLeonida:old-pr/10030
ProjectLeonida:old-pr/10040
ProjectLeonida:old-pr/9990
ProjectLeonida:old-pr/10021
ProjectLeonida:old-pr/9962
ProjectLeonida:old-pr/10022
ProjectLeonida:old-pr/10020
ProjectLeonida:old-pr/10015
ProjectLeonida:old-pr/10025
ProjectLeonida:old-pr/9886
ProjectLeonida:old-pr/10048
ProjectLeonida:old-pr/10014
ProjectLeonida:old-pr/10011
ProjectLeonida:old-pr/9861
ProjectLeonida:old-pr/10010
ProjectLeonida:old-pr/10008
ProjectLeonida:old-pr/9860
ProjectLeonida:old-pr/10006
ProjectLeonida:old-pr/9920
ProjectLeonida:old-pr/9995
ProjectLeonida:old-pr/10000
ProjectLeonida:old-pr/10016
ProjectLeonida:old-pr/10004
ProjectLeonida:old-pr/10023
ProjectLeonida:old-pr/9982
ProjectLeonida:old-pr/9981
ProjectLeonida:old-pr/9983
ProjectLeonida:old-pr/9970
ProjectLeonida:old-pr/9969
ProjectLeonida:old-pr/9968
ProjectLeonida:old-pr/9971
ProjectLeonida:old-pr/9972
ProjectLeonida:old-pr/9942
ProjectLeonida:old-pr/9963
ProjectLeonida:old-pr/9960
ProjectLeonida:old-pr/9964
ProjectLeonida:old-pr/9985
ProjectLeonida:old-pr/9973
ProjectLeonida:old-pr/9862
ProjectLeonida:old-pr/9953
ProjectLeonida:old-pr/10017
ProjectLeonida:old-pr/9952
ProjectLeonida:old-pr/9955
ProjectLeonida:old-pr/9946
ProjectLeonida:old-pr/9954
ProjectLeonida:old-pr/9938
ProjectLeonida:old-pr/9956
ProjectLeonida:old-pr/9856
ProjectLeonida:old-pr/9947
ProjectLeonida:old-pr/9924
ProjectLeonida:old-pr/9961
ProjectLeonida:old-pr/9927
ProjectLeonida:old-pr/9979
ProjectLeonida:old-pr/10032
ProjectLeonida:old-pr/9926
ProjectLeonida:old-pr/5237
ProjectLeonida:old-pr/9951
ProjectLeonida:old-pr/9931
ProjectLeonida:old-pr/9902
ProjectLeonida:old-pr/9921
ProjectLeonida:old-pr/9994
ProjectLeonida:old-pr/9775
ProjectLeonida:old-pr/9768
ProjectLeonida:old-pr/9905
ProjectLeonida:old-pr/9936
ProjectLeonida:old-pr/9901
ProjectLeonida:old-pr/9904
ProjectLeonida:old-pr/9906
ProjectLeonida:old-pr/9988
ProjectLeonida:old-pr/9908
ProjectLeonida:old-pr/9909
ProjectLeonida:old-pr/9911
ProjectLeonida:old-pr/9912
ProjectLeonida:old-pr/9913
ProjectLeonida:old-pr/9887
ProjectLeonida:old-pr/9916
ProjectLeonida:old-pr/9919
ProjectLeonida:old-pr/9925
ProjectLeonida:old-pr/9933
ProjectLeonida:old-pr/9935
ProjectLeonida:old-pr/9918
ProjectLeonida:old-pr/9879
ProjectLeonida:old-pr/9880
ProjectLeonida:old-pr/9881
ProjectLeonida:old-pr/9996
ProjectLeonida:old-pr/9876
ProjectLeonida:old-pr/9892
ProjectLeonida:old-pr/9899
ProjectLeonida:old-pr/9915
ProjectLeonida:old-pr/9914
ProjectLeonida:old-pr/9872
ProjectLeonida:old-pr/9869
ProjectLeonida:old-pr/9866
ProjectLeonida:old-pr/9819
ProjectLeonida:old-pr/10012
ProjectLeonida:old-pr/9857
ProjectLeonida:old-pr/9893
ProjectLeonida:old-pr/9897
ProjectLeonida:old-pr/9928
ProjectLeonida:old-pr/9868
ProjectLeonida:old-pr/9917
ProjectLeonida:old-pr/9940
ProjectLeonida:old-pr/9873
ProjectLeonida:old-pr/9816
ProjectLeonida:old-pr/10009
ProjectLeonida:old-pr/9900
ProjectLeonida:old-pr/9966
ProjectLeonida:old-pr/9859
ProjectLeonida:old-pr/9843
ProjectLeonida:old-pr/9991
ProjectLeonida:old-pr/10058
ProjectLeonida:old-pr/9883
ProjectLeonida:old-pr/9838
ProjectLeonida:old-pr/9835
ProjectLeonida:old-pr/9959
ProjectLeonida:old-pr/9895
ProjectLeonida:old-pr/9837
ProjectLeonida:old-pr/9858
ProjectLeonida:old-pr/9865
ProjectLeonida:old-pr/9864
ProjectLeonida:old-pr/9840
ProjectLeonida:old-pr/9820
ProjectLeonida:old-pr/4669
ProjectLeonida:old-pr/9848
ProjectLeonida:old-pr/9850
ProjectLeonida:old-pr/9810
ProjectLeonida:old-pr/9799
ProjectLeonida:old-pr/9853
ProjectLeonida:old-pr/9875
ProjectLeonida:old-pr/9831
ProjectLeonida:old-pr/9796
ProjectLeonida:old-pr/9801
ProjectLeonida:old-pr/9813
ProjectLeonida:old-pr/9794
ProjectLeonida:old-pr/7417
ProjectLeonida:old-pr/9781
ProjectLeonida:old-pr/9806
ProjectLeonida:old-pr/9958
ProjectLeonida:old-pr/9809
ProjectLeonida:old-pr/9791
ProjectLeonida:old-pr/9792
ProjectLeonida:old-pr/10053
ProjectLeonida:old-pr/9784
ProjectLeonida:old-pr/9789
ProjectLeonida:old-pr/9849
ProjectLeonida:old-pr/9846
ProjectLeonida:old-pr/9773
ProjectLeonida:old-pr/9785
ProjectLeonida:old-pr/9803
ProjectLeonida:old-pr/9826
ProjectLeonida:old-pr/9839
ProjectLeonida:old-pr/9922
ProjectLeonida:old-pr/9948
ProjectLeonida:old-pr/7189
ProjectLeonida:old-pr/9957
ProjectLeonida:old-pr/9823
ProjectLeonida:old-pr/9807
ProjectLeonida:old-pr/9851
ProjectLeonida:old-pr/9774
ProjectLeonida:old-pr/9830
ProjectLeonida:old-pr/9836
ProjectLeonida:old-pr/9822
ProjectLeonida:old-pr/9783
ProjectLeonida:old-pr/9833
ProjectLeonida:old-pr/9890
ProjectLeonida:old-pr/9770
ProjectLeonida:old-pr/9769
ProjectLeonida:old-pr/9772
ProjectLeonida:old-pr/9787
ProjectLeonida:old-pr/9852
ProjectLeonida:old-pr/9834
ProjectLeonida:old-pr/9845
ProjectLeonida:old-pr/9871
ProjectLeonida:old-pr/9771
ProjectLeonida:old-pr/9776
ProjectLeonida:old-pr/10005
ProjectLeonida:old-pr/9949
ProjectLeonida:old-pr/9923
ProjectLeonida:old-pr/9805
ProjectLeonida:old-pr/9829
ProjectLeonida:old-pr/9790
ProjectLeonida:old-pr/9827
ProjectLeonida:old-pr/9929
ProjectLeonida:old-pr/9855
ProjectLeonida:old-pr/9934
ProjectLeonida:old-pr/9907
ProjectLeonida:old-pr/9910
ProjectLeonida:old-pr/9779
ProjectLeonida:old-pr/9780
ProjectLeonida:old-pr/9885
ProjectLeonida:old-pr/9882
ProjectLeonida:old-pr/9877
ProjectLeonida:old-pr/9998
ProjectLeonida:old-pr/4251
ProjectLeonida:old-pr/9987
ProjectLeonida:old-pr/9989
ProjectLeonida:old-pr/9950
ProjectLeonida:old-pr/9777
ProjectLeonida:old-pr/10044
ProjectLeonida:old-pr/9884
ProjectLeonida:old-pr/2906
ProjectLeonida:old-pr/5076
ProjectLeonida:old-pr/9937
ProjectLeonida:old-pr/9986
ProjectLeonida:old-pr/3014
ProjectLeonida:old-pr/9943
ProjectLeonida:old-pr/9939
ProjectLeonida:old-pr/4682
ProjectLeonida:old-pr/4765
No reviewers
Labels
Clear labels
No items
No labels
Milestone
Clear milestone
No items
No milestone
Assignees
Clear assignees
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.
Reference
ProjectLeonida/mandy!2855
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/2855"
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?
Imported from ubiquitarianism/leonida. Originally posted by lixonik on 2026-12-01T09:38:30Z.
Claim:
D3D12-TEST-DEPTH-BOUNDS-WIN10(https://github.com/ProjectLeonida/mandy/issues/2570#issuecomment-7306935341)Fixes
pipeline::host::tests::depth_bounds_pipeline_loads_and_filters_drawsfailing deterministically on Windows 10 (HRESULT(0x80070057)/E_INVALIDARG), and shares the same unflagged empty root signature helper witha_mesh_pipeline_loads_from_the_library.Root cause
Unit-test binaries do not export
D3D12SDKVersion/D3D12SDKPathand therefore run against inboxd3d12.dll. On Windows 10 22H2 (build 19045), inboxd3d12.dllrejectsD3D12_ROOT_SIGNATURE_FLAG_CBV_SRV_UAV_HEAP_DIRECTLY_INDEXED | D3D12_ROOT_SIGNATURE_FLAG_SAMPLER_HEAP_DIRECTLY_INDEXED(SM 6.6) passed byroot_signature(...)withE_INVALIDARG(0x80070057), even though these tests'vs_6_5/ms_6_5/ps_6_5shaders bind zero descriptors.Change
In
d3d12/crates/leonida-gpu/src/pipeline/host.rs:root_signature_with_flags(device, params, samplers, flags)out ofroot_signature(...)(keeping productionroot_signature(...)behaviorally identical withinput | CBV_SRV_UAV_HEAP_DIRECTLY_INDEXED | SAMPLER_HEAP_DIRECTLY_INDEXEDandLEONIDA_ROOT_DEDUPEcaching intact).depth_bounds_pipeline_loads_and_filters_drawsanda_mesh_pipeline_loads_from_the_libraryto callroot_signature_with_flags(&host.device, &[], &[], D3D12_ROOT_SIGNATURE_FLAG_ALLOW_INPUT_ASSEMBLER_INPUT_LAYOUT), avoiding duplicated serialization boilerplate and keeping the production root-signature helper exercised on every host.Verification
mainad7c62edb, solo and 8/8 parallel runs):depth_bounds_pipeline_loads_and_filters_drawspanicked atpipeline/host.rs:1625:79withHRESULT(0x80070057).31752c4da):cargo test --locked -p leonida-gpu --lib pipeline::host:: -- --nocapture: 9 passed, 0 failed (depth_bounds_pipeline_loads_and_filters_drawsexecuted full GPU depth-bounds PSO load, draw, replay, and readback without skipping;a_mesh_pipeline_loads_from_the_libraryskips on Win10 inboxd3d12.dllbefore root-signature creation as expected).python -I scripts/check_no_game_data.py: clean.GPUs tested: NVIDIA GeForce RTX 5070 12 GB (driver 621.40, Windows 10 Pro 22H2 build 19045, Ryzen 9 5950X 16C/32T)
AI-assisted: Antigravity (plus separate read-only reviewer subagent)
Imported from ubiquitarianism/leonida. Originally posted by MoonEyes on 2026-12-01T10:04:46Z.
Your claim is there (
D3D12-TEST-DEPTH-BOUNDS-WIN10, https://github.com/ProjectLeonida/mandy/issues/2570#issuecomment-7306935341), but the description does not name it. Could you add the ID and that link, so the merge checklist finds it?AI-assisted (Claude Code).
Imported from ubiquitarianism/leonida. Originally posted by lixonik on 2026-12-01T11:16:22Z.
@MoonEyes Added the claim ID (
D3D12-TEST-DEPTH-BOUNDS-WIN10) and link to the PR description.AI-assisted: Antigravity
Imported from ubiquitarianism/leonida. Originally posted by enlight3d on 2026-12-01T11:18:14Z.
RUN (independent run on Windows, #2855 head
45f7be90b, merged locally into main3393ceec9withgit merge --no-ff, no conflicts. The head still merges cleanly into mainbf30e2585. CI on the head: change-scope, check, linux-python-and-viewer, no-game-data and semantic-tests all pass.)This machine runs Windows 11 Pro 26300, where the test does not fail on main. The red in the body (
E_INVALIDARGfrom the inboxd3d12.dllof Windows 10 22H2) cannot be reproduced here; this run checks that the test still passes and still tests something on Windows 11.Commands, in
d3d12/, target x86_64-pc-windows-msvc, toolchain 1.98.1, all with--locked, at low priority:cargo test -p leonida-gpu --lib pipeline::host::tests::depth_bounds_pipeline_loads_and_filters_draws -- --exact --nocapture: passes on main (0.33 s) and on the merge (0.30 s). Neither run prints "no host depth bounds support; skipped" or "no PC dxc.exe; skipped", so the test gets past both early returns and runs its two draws on the RTX 3090.OMSetDepthBoundstaken out ofdraw::depth_bounds(production code), the test fails on its first draw check, "depth 0.5 outside [0.6, 1.0] must be rejected", left 255, right 0. So the bounds set throughState::set_depth_boundsand replayed byState::replayare what reject that draw. Restored: passes again.cargo test -p leonida-gpu --lib --no-fail-faston the merge: 601 passed / 0 failed / 55 ignored; with--features diagnostics: 681 / 0 / 55. Main at the same commit: 601 / 0 / 55 in 31 of 32 parallel runs (one watch test failed once, see the #2854 run).cargo clippy -p leonida-gpu --all-targets, default and--features diagnostics, main and merge: the same warnings on both sides, none new.ALLOW_INPUT_ASSEMBLER_INPUT_LAYOUT). It no longer goes through the runtime'sroot_signature(...), so it no longer checks a depth-bounds pipeline with the runtime's own root signature and its SM 6.6 heap flags. The runtime is unchanged.Not covered: Windows 10 (the red), other GPUs.
Machine: Windows 11 Pro 26300, i9-13900K, 64 GB, RTX 3090 24 GB, NVIDIA 621.40, Rust 1.98.1.
Imported from ubiquitarianism/leonida. Originally posted by MoonEyes on 2026-12-01T15:19:11Z.
Verified by MoonEyes (another person than the author) on head
45f7be90bmerged withmaincd0c52fcf: I read the whole diff. A test only.cargo test -p leonida-gpu: the only failure seen,committed_and_placed_r32_uint_textures_cast_to_r9g9b9e5_under_legacy_barriers, fails in 2 of 5 parallel runs of plainmaintoo. On Windows 11 it is green on both sides; the red is for Windows 10.In-game run with the six others of a batch on
main21e6bbf4b: RTX 4060 8 GB, NVIDIA 610.88, Windows 11 26300,-SeriesS -FrameGen 2, about 860 s in the world, then a second one of about 440 s, 0 device lost, 0 panic; pictures of the same scene compared withmain, same. Black surfaces in early cutscenes while the PC's memory is full are there on plainmaintoo.AI-assisted (Claude Code).
Imported from ubiquitarianism/leonida. Originally posted by imShangLi on 2026-12-01T15:21:41Z.
VERIFY-2855 — Linux, Rust 1.98.1 (the pinned toolchain), no GPU device, no game files
Verdict: PASS on what I could check, and one gap worth closing. The change is right and its API use is exact — I checked every field name and function signature against the
windowscrate's own source. It cannot be run here (it needs Windows, a D3D12 device and DXC), and I found one sibling test with the same problem that this pull request does not fix.Head
45f7be90, base the currentmain88a9f133, merge base7fbcd456, 1 commit, 1 file, +30/−1:d3d12/crates/leonida-gpu/src/pipeline/host.rs.1. What it changes
The test
depth_bounds_pipeline_loads_and_filters_drawsbuilt its root signature withroot_signature(&host.device, &[], &[], false). That helper always adds the SM 6.6 flags:The pull request builds the same empty versioned root signature inline, with only
D3D12_ROOT_SIGNATURE_FLAG_ALLOW_INPUT_ASSEMBLER_INPUT_LAYOUT, so no SM 6.6 flag is set.2. The flags are the SM 6.6 ones
From
windows-0.62.2/src/Windows/Win32/Graphics/Direct3D12/mod.rs:D3D12_ROOT_SIGNATURE_FLAG_CBV_SRV_UAV_HEAP_DIRECTLY_INDEXEDand..._SAMPLER_HEAP_DIRECTLY_INDEXEDare the two root-signature flags that arrived with shader model 6.6 (D3D12 1.3), so dropping them is dropping SM 6.6. ✓3. The API use matches the crate exactly
I checked every name the new code uses against the
windows0.62.2 source:D3D12_VERSIONED_ROOT_SIGNATURE_DESC { Version, Anonymous }pub Version: D3D_ROOT_SIGNATURE_VERSION,pub Anonymous: D3D12_VERSIONED_ROOT_SIGNATURE_DESC_0D3D12_VERSIONED_ROOT_SIGNATURE_DESC_0 { Desc_1_1: D3D12_ROOT_SIGNATURE_DESC1 { .. } }pub union … { pub Desc_1_0: D3D12_ROOT_SIGNATURE_DESC, pub Desc_1_1: D3D12_ROOT_SIGNATURE_DESC1, pub Desc_1_2: … }D3D12_ROOT_SIGNATURE_DESC1 { NumParameters, pParameters, NumStaticSamplers, pStaticSamplers, Flags }pParameters: *const D3D12_ROOT_PARAMETER1,pStaticSamplers: *const D3D12_STATIC_SAMPLER_DESC,Flags: D3D12_ROOT_SIGNATURE_FLAGSD3D12SerializeVersionedRootSignature(&desc, &mut blob, None)pub unsafe fn D3D12SerializeVersionedRootSignature(prootsignature: *const D3D12_VERSIONED_ROOT_SIGNATURE_DESC, ppblob: *mut Option<ID3DBlob>, pperrorblob: Option<*mut Option<ID3DBlob>>) -> windows_core::Result<()>— the third argument is anOption, soNoneis rightblob.GetBufferPointer().cast::<u8>(),blob.GetBufferSize()pub unsafe fn GetBufferPointer(&self) -> *mut core::ffi::c_void,pub unsafe fn GetBufferSize(&self) -> usizehost.device.CreateRootSignature(0, &bytes)pub unsafe fn CreateRootSignature<T: Interface>(&self, nodemask: u32, pblobwithrootsignature: &[u8]) -> windows_core::Result<T>The types are in scope:
pipeline/host.rs:12-13hasuse windows::Win32::Graphics::Direct3D::ID3DBlob;anduse windows::Win32::Graphics::Direct3D12::*;, and the test module hasuse super::*;.The new code also copies the blob into a
Vecbefore dropping theID3DBlob, which the helper it replaces does not have to do (it reads the blob while it is still alive). That is the safer of the two. ✓4. An empty root signature is the right thing here
The pull request says "the shaders bind no descriptors". The two shaders the test compiles are:
Neither reads a resource, so there is nothing for a root parameter to bind. ✓ An empty root signature is correct.
The production path is untouched:
pipeline/host.rs:826still callsroot_signature(&host.device, ¶ms, &samplers, …)with real parameters, so the runtime keeps the heap-direct-indexing flags it needs.5. The sibling test with the same problem
a_mesh_pipeline_loads_from_the_librarymakes the same call with the same empty parameters:so it hits the same SM 6.6 flags, and the same inbox
d3d12.dllwould reject them the same way. This pull request does not touch it. If the reason for the change is "inboxd3d12.dllrejects SM 6.6 root signature flags", the sibling needs the same treatment.A cheaper way to cover both, if the maintainer prefers it:
root_signature()could leave the two*_HEAP_DIRECTLY_INDEXEDflags off when there are no root parameters and no static samplers — an empty root signature has no descriptors for the flags to apply to — and both tests would then need no change at all. I did not measure that on Windows; it is a suggestion about where to put the fix, not a claim that the pull request is wrong.6. What this pull request does and does not affect in CI
.github/workflows/d3d12.yml:76runs the workspace tests withso the test this pull request changes does not run in CI at all. The fix is for a developer running
cargo test -p leonida-gpuon Windows with DXC and a host device. Worth knowing when judging how urgent the sibling in §5 is.7. What I did not check
dxc.exe, a host GPU with depth-bounds support, and the inboxd3d12.dll; the crate does not build on Linux (upstream's own words: "The crates are Windows-only today (leonida-gpu does not build on macOS); Linux follows #2577 if it lands"). So the claim that inboxd3d12.dllanswersE_INVALIDARGfor these flags is the pull request's, and I could not confirm it on a Windows machine.E_INVALIDARGclaim's Windows version. The comment says "on Windows 10"; the CI runner is Windows 11. I did not check which inbox D3D12 version each carries.cargo clippyandcargo fmt— the workflow runs clippy as a report only (it already fails onmain), and formatting is left out of the d3d12 workflow.library::name(…),pipeline/host.rs:1668), which only means the test's pipeline is cached under a different name. I did not check the library code.AI-assisted: MiniMax M3.1 Flash.
Imported from ubiquitarianism/leonida. Originally posted by merzleckeier on 2026-12-01T15:44:49Z.
I mirrored the two exact empty v1.1 root descriptors in a native inbox root-signature A/B. The base flags are 0xC01 (input assembler, CBV/SRV/UAV heap indexing, sampler heap indexing). The PR flags are 0x1. On both GitHub-hosted Windows Server 2022 and 2025 I created the Microsoft Basic Render Driver via EnumWarpAdapter and logged serialization and CreateRootSignature separately.
The lean descriptor works on both inbox versions. Server 2022 also accepts the old flags despite reporting SM 6.2, so the Windows 10 19045 rejection is still a separate platform result. This checks signature creation, with no rendering workload.
Server 2022 log · Server 2025 log · MEASURED, AI-assisted (Codex).
Imported from ubiquitarianism/leonida. Originally posted by lixonik on 2026-12-01T16:30:02Z.
@imShangLi Thanks for the thorough audit! Two notes on §5:
621.40):a_mesh_pipeline_loads_from_the_libraryreturns early beforeroot_signature()(no host mesh shader support; skipped), because Windows 10 inboxd3d12.dlldoes not expose mesh shaders without Agility SDK, whereas Agility SDK / Windows 11 already accept the SM 6.6 root signature flags.root_signature()intentionally keeps*_HEAP_DIRECTLY_INDEXEDeven whenparamsandsamplersare empty, because an SM 6.6 shader readingResourceDescriptorHeap/SamplerDescriptorHeapdirectly can bind zero root parameters.@merzleckeier Thanks for the Server 2022/2025 WARP check as well!
Imported from ubiquitarianism/leonida. Originally posted by KelboLive on 2026-12-01T17:52:12Z.
Review: COMMENTED
Test-only, and the root cause checks out:
root_signature()adds the two SM 6.6 flags unconditionally (host.rs:1322-1324), the app exportsD3D12SDKVersion/D3D12SDKPath(apps/leonida/src/agility.rs:33,49) while test binaries do not, and thesevs_6_5/ps_6_5shaders bind no descriptors — so the empty v1.1 signature is right and production stays on the flagged path.Verified on Windows 11 / RTX 4070 Ti SUPER: the test passes without skipping, the lib suite is 600/0/55, and replacing the production
OMSetDepthBoundswith(0.0, 1.0)still fails it athost.rs:1883(left 255, right 0), so the depth-bounds assertions still bite.Two notes before merge:
root_signature(...).root_signature()is only exercised bya_mesh_pipeline_loads_from_the_library(:1529), which skips on Windows 10. Aroot_signature_with_flags(...)argument would avoid the 30 duplicated lines and keep the production helper covered on every host.Minor, expected: switching
ALLOW_INPUT_ASSEMBLER_INPUT_LAYOUTtoNONEstill passes, since the test binds no input layout — the flag is not load-bearing here.Merge is clean against current main;
host.rsis unchanged upstream since the base, so the 380-commit gap is not drift.Imported from ubiquitarianism/leonida. Originally posted by imShangLi on 2026-12-01T17:59:27Z.
The same call is made one function up, and this change leaves it alone.
d3d12/crates/leonida-gpu/src/pipeline/host.rs:1529— ina_mesh_pipeline_loads_from_the_library:root_signature()(host.rs:1303) adds the two shader-model 6.6 flags to every root signature it builds:(
0x400and0x800inwindows-0.62.2.) The shaders of that test bind no descriptors either, so the inline empty root signature this pull request writes for the depth-bounds test would serve it just as well — but as it stands the mesh test still asks for an SM 6.6 root signature, and the inboxd3d12.dllthat rejects those flags withE_INVALIDARGwould reject that one the same way.It does not show up in CI either way: the mesh test needs a host GPU with mesh shader support and a
dxc.exe(it returns early with// no host GPU here), andleonida-gpu's library tests need a device.Two ways this could go, both fine by me:
I did not touch it myself:
leonida-gpudoes not build on Linux (upstream: "The crates are Windows-only today ... Linux follows #2577 if it lands"), so I could not run the test either.Verified against
mainin https://github.com/ProjectLeonida/mandy/pull/2855#issuecomment-7315780799AI-assisted.
Imported from ubiquitarianism/leonida. Originally posted by lixonik on 2026-12-01T21:02:02Z.
@KelboLive @imShangLi Thanks for both suggestions! Factored
root_signature_with_flags(device, params, samplers, flags)in31752c4da:root_signature(...)delegates toroot_signature_with_flags(...)with the exact sameinput | CBV_SRV_UAV_HEAP_DIRECTLY_INDEXED | SAMPLER_HEAP_DIRECTLY_INDEXEDflags andLEONIDA_ROOT_DEDUPEcaching (MADEkeys on the serialized blob bytes, which encodeFlags, so flagged and unflagged signatures cannot collide).depth_bounds_pipeline_loads_and_filters_drawsanda_mesh_pipeline_loads_from_the_librarynow callroot_signature_with_flags(&host.device, &[], &[], D3D12_ROOT_SIGNATURE_FLAG_ALLOW_INPUT_ASSEMBLER_INPUT_LAYOUT)-- removing the 30-line inline duplication, keeping the production helper exercised on every host, and leaving no need for a separate mesh-test follow-up.Re-verified
cargo test --locked -p leonida-gpu --lib pipeline::host:: -- --nocapture(9 passed, 0 failed on Windows 10 22H2 / RTX 5070) andscripts/check_no_game_data.py. (Noted the#2663overlap on thedepth_boundshunk -- the diff there is now a single helper call instead of 30 lines.)Imported from ubiquitarianism/leonida. Originally posted by lixonik on 2026-12-02T01:30:34Z.
Merged
origin/main(393901a5b, including #2663) cleanly in5e4cd9bcb:vs_6_0/ps_6_0shader targets indepth_bounds_pipeline_loads_and_filters_drawsalongsideroot_signature_with_flags(...).depth_bounds_without_depth_test_filters_on_warp_and_in_parallel(run_parallel_depth_bounds_check, also descriptor-lessvs_6_0/ps_6_0) toroot_signature_with_flags(...)so it executes on Windows 10 inboxd3d12.dllinstead of skipping.Re-verified
cargo test --locked -p leonida-gpu --lib pipeline::host:: -- --nocaptureon Windows 10 Pro 22H2 / RTX 5070: 11 passed, 0 failed (bothdepth_bounds_pipeline_loads_and_filters_drawsanddepth_bounds_without_depth_test_filters_on_warp_and_in_parallelran without skipping) andpython -I scripts/check_no_game_data.py.Imported from ubiquitarianism/leonida. Originally posted by MoonEyes on 2026-12-02T12:29:24Z.
This pull request touches the render path, so it needs an in-game run before it can be merged: unit tests and CI do not catch rendering regressions (a device loss after an earlier merge is why this gate exists).
Could you, or anyone with a working setup, post a run report on the current head merged onto current
main:mainSHA it was merged onto;mainalone for comparison, if you can.Please do not attach logs or screenshots that show game content. If a run on this exact head is already posted, a link to it in a reply is enough.
AI-assisted (Claude Code).
Imported from ubiquitarianism/leonida. Originally posted by lixonik on 2026-12-02T13:59:01Z.
RUN (in game): head
5e4cd9bcbmerged cleanly (git merge --no-ff) ontomainbf7886746, built withcargo build --locked --profile diag -p leonida --features diagnostics,dlss,mimalloc, plus a matchedmainbf7886746baseline run on the same save snapshot.621.40(Series S profile,-NoFrameGen -NoPrecompile, standing in-world).#2855(5e4cd9bcbonbf7886746): 316.1 s (63 world frame lines)main(bf7886746) baseline: 319.2 s (62 world frame lines)ERRORlines: 0 (both runs)tools/d3d12_run_fps.py):main(bf7886746)#2855(5e4cd9bcb)Result: PASS.
AI-assisted: yes (Antigravity).
Imported from ubiquitarianism/leonida. Originally posted by MoonEyes on 2026-12-02T15:53:36Z.
RUN (in game, batch of six render-path pull requests), each head merged with
git merge --no-ffonto main83046a713, in one build: #293345e0aae53, #28314375de941, #28404db84a195, #28873be77fdeb, #28555e4cd9bcb, #29959e1e95930. RTX 4060 8 GB, driver 610.88, Windows 11. Series S,-Resolution 1080, frame generation 2x, the same walking route as the other runs on this machine, 330 s after reaching the world.For reference, the same machine and route rendered 13.3 to 15.2 fps today on main with single pull requests and 14.9 with the first batch; no compile ran beside the game this time. These fps are a check that nothing fell over, not a measurement of a gain.
Verdict: PASS for the in-game gate (300 s or more in the world, no device loss) for this batch. If one of these pull requests changes its head, this run no longer covers it.
Limits: one run; free system memory was low (median 1.3 GB); arrival in the world was driven by keys and not checked on pictures.
AI-assisted (Claude Code).
Imported from ubiquitarianism/leonida. Originally posted by MoonEyes on 2026-12-02T18:01:09Z.
Triage of head
5e4cd9bcb(merge base393901a5b, 210 commits behind;git merge-treeagainst currentmain45dc41f95: no conflicts).1 file:
d3d12/crates/leonida-gpu/src/pipeline/host.rs(+43/-6), test only.CI green on the head (6 checks).
Existing verification: Verified by @MoonEyes, @imShangLi, @merzleckeier (root-signature A/B on Server 2022/2025), @lixonik (in game on this head) and @MoonEyes's six-PR in-game batch on
83046a713.This check: Test-only:
root_signature_with_flagslets the depth-bounds and mesh tests drop the SM 6.6 heap-indexing flags Windows 10 rejects; productionroot_signaturedelegates with its flags unchanged. AGENTS.md's canonical command still has--skip depth_bounds_pipeline_loads_and_filters_draws; once this lands that skip can be revisited (a separate change).I did not build it: the crate is Windows-only (or the C++ runtime's Windows build), so no red/green was run here.
Verdict: ready (test-only, verified many times including in game).
AI-assisted verification: Claude Opus (Claude Code), separate agent per batch.
Generated by Claude Code
Imported from ubiquitarianism/leonida. Originally posted by fiestorra on 2026-12-03T03:26:05Z.
VERIFY-2855 — el test que su título dice que existe no está en el diff
Un fichero,
pipeline/host.rs, +43/−6, once días abierto.Lo primero, la suite:
Y la única falla es la de la iGPU (
descriptor::host::tests::views_are_made_beside_the_heap_and_copied_from), la misma que enmainsin esta PR — lo comprobé en#2841y#2892con el test suelto.Lo segundo, que es lo que este comentario tiene de distinto: busqué los tests nuevos de la rama y no hay ninguno.
git diffno añade ni unafn …()con#[test].Y el título dice «drop unused SM 6.6 root signature flags in depth_bounds test» — «in depth_bounds test», un cambio en un test. Por la forma del diff (
+43/−6enpipeline/host.rs) parece más que quitar dos banderas, así que probablemente el cambio modifica tests existentes en vez de añadir uno — que es legítimo, y es justo el caso en que un revisor tiene que leer los tests viejos para saber qué cambió en lo que ya se comprobaba.Lo que no puedo decir sin leerlos: si la prueba sigue probando lo mismo. Un test cuyo arreglo consiste en quitarle banderas puede pasar por dejar de ejercitar el camino que fallaba — y eso es lo que hay que mirar aquí, no si el verde está verde.
Lo que probé y lo que no: la suite entera pasa menos la falla conocida, y eso dice que el cambio no rompe nada; no dice que el test siga siendo el mismo test.
Si el autor puede decir en una línea qué aserción cambió y por qué, con eso se cierra — y si no, lo leo yo en la próxima pasada.
Imported from ubiquitarianism/leonida. Originally posted by fiestorra on 2026-12-03T03:26:41Z.
I read the tests, and the answer is better and worse than I guessed
What the change actually does (I said I would open it, so here it is):
and every test that used
root_signature(device, &[], &[], false)now callsroot_signature_with_flags(…, ALLOW_INPUT_ASSEMBLER_INPUT_LAYOUT)instead.So it is not "removing assertions" — the tests still create a root signature, serialise it and check the blob — and the reason is written at each call site:
And that sentence is the whole change: the inbox
d3d12.dllrejects SM 6.6 root-signature flags on Windows 10, so a test that passed them could never pass there. The fix is to stop asking the test machine for a capability the test does not need.But the consequence is the one worth naming, and it is not a defect: this pull request removes the only coverage of
root_signaturebeing created with the SM 6.6 flags. Before it, that path was exercised by tests that then failed on Windows 10; after it, the path is exercised by nothing. The alternative —#[cfg]or a skip when the device does not advertise the capability — would keep the coverage where it can run and skip where it cannot, which is exactly what I argued for inhle-visible-stylean hour ago.So my answer to my own question: the assertions are intact, the flags moved out of the tests for a documented reason, and the trade is coverage of the 6.6 path. If the author wants that coverage back, it is a
caps()check and a skip, not a revert — and if the Windows 10 case is the one that matters, then this is right as it stands and the 6.6 path is tested on the machines that have it, if any test does.Imported from ubiquitarianism/leonida. Originally posted by lixonik on 2026-12-03T03:28:02Z.
Thanks @fiestorra for reading through the diff and checking the assertions!
Two quick clarifications:
depth_bounds_pipeline_loads_and_filters_drawsand thems_6_5/ps_6_5tests is unchanged -- those shaders are SM 6.0 / SM 6.5 and bind zero descriptors, so they never exercised SM 6.6 dynamic-resource indexing; the*_HEAP_DIRECTLY_INDEXEDflags only brokeCreateRootSignatureon Windows 10's inboxd3d12.dll(no Agility SDK export in thecargo testbinary).root_signature(...)(with the SM 6.6*_HEAP_DIRECTLY_INDEXEDflags) is unchanged and remains the path called bypipeline/host.rspipeline creation (line 838) and by tests that go through full host pipeline creation / the runtime; keeping5e4cd9bcbas-is also preserves the batch-gate PASS already posted on this head.AI-assisted: yes (Antigravity -- Gemini 4 Neon).
View command line instructions
Checkout
From your project repository, check out a new branch and test the changes.Merge
Merge the changes and update on Forgejo.Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.