upleb.uk

Public git repos — served from a NIP-34 GRASP relay at git.upleb.uk

summaryrefslogtreecommitdiff
path: root/docs/d3d12_vulkan.md
diff options
context:
space:
mode:
authorQemmHD <stephenlethco2@gmail.com>2026-11-24 21:35:06 -0500
committerGitHub <noreply@github.com>2026-11-24 21:35:06 -0500
commita2de554e5632345f9c9fcb18783eb40eabbe8a22 (patch)
tree1a7512f01e8c74eb5293fa12e051e43b3a1ef849 /docs/d3d12_vulkan.md
parente79906a42b20a676231ba677a383b37af25a37ba (diff)
parenta330747f237b7ce1d2cc82a531ef5d2220ee9c20 (diff)
Merge pull request #1353 from robot00f/fix/rootsig-heap-flags
Merging. **Why merged:** on Windows 10, the in-box `d3d12.dll` refuses root-signature flags `0xC00` (heap directly indexed) in its serializer, so the title is left with a null program and stops about 15 s in (`exe+0xb5a5f8`, a read of `0x68`); testers on Windows 10 hit this every boot. This retries only after the host has refused, and only when `0xC00` is in the description. It covers both the versioned and the legacy `D3D12SerializeRootSignature`, patches the flags back into `RTS0` after checking the container hash (failing closed), and it's claimed as D3D12-SET-HEAPS-BLOB. It's the better of the two PRs for this. #683 does the same for the versioned path only, by probing each bit through a static that captures the first serializer pointer. **Why it's good:** on this Windows 11 host the real serializer accepts the flags, so I also checked the refusal path independently with a harness: a fake serializer that refuses `0xC00` and forwards everything else to the real Windows 11 serializer, on the RTX 4070 SUPER's hardware D3D12 device. #1353's wrappers (versioned 1.0 and 1.1, legacy 1.0) return S_OK after exactly one refusal; the flags read back as `0xc01` through the host deserializer; hardware `CreateRootSignature` succeeds; an unrelated failure is passed through; and a host that accepts the flags gets a byte-identical blob, 16/16. root_sig, root_signature, root_signature_oracle, d3d12_set_descriptor_heaps, d3d12_xs_root_signature, d3d12_draw, bundle, device_proxy and xs_proxy_mock* pass 14/14, both plain and with `LEONIDA_VK_VALIDATION=1`. The repository-consistency set gives 578/5/0. It merges cleanly onto main after #984 (neither #984 nor DadaCap's prototype carries this fix). Minor note: it returns S_FALSE ("flags lost") if a blob can't be patched, which is fine. AI-assisted (Claude Code, Claude Opus 5.5).
Diffstat (limited to 'docs/d3d12_vulkan.md')
-rw-r--r--docs/d3d12_vulkan.md11
1 files changed, 11 insertions, 0 deletions
diff --git a/docs/d3d12_vulkan.md b/docs/d3d12_vulkan.md
index 223eee0f7..d365f4663 100644
--- a/docs/d3d12_vulkan.md
+++ b/docs/d3d12_vulkan.md
@@ -2042,6 +2042,17 @@ UINT border colour or non-normalized coordinates) with a log line, since 1.1 can
2042once with an empty 1.2 description. `root_sig_test` checks the rewrite field by field and through the host 2042once with an empty 1.2 description. `root_sig_test` checks the rewrite field by field and through the host
2043deserializer. 2043deserializer.
2044 2044
2045**Heap-directly-indexed flags on older runtimes.** The same in-box `d3d12.dll` refuses
2046`D3D12_ROOT_SIGNATURE_FLAG_CBV_SRV_UAV_HEAP_DIRECTLY_INDEXED` and `..._SAMPLER_HEAP_DIRECTLY_INDEXED` in the
2047serializer at every descriptor version, with `E_INVALIDARG` and "Unsupported bit-flag set (root signature flags c00)"
2048(measured on 10.0.19041.4355; 1.0 and 1.1 both fail). Its *deserializer* and its devices take a blob that carries
2049them: a blob serialized without the bits, patched back in and re-hashed deserializes with `Flags = 0xc00` and creates
2050a WARP root signature. So the `d3d12_xs` serializer, when the host refuses and the description sets either bit,
2051serializes again with the bits cleared and puts them back into the produced `RTS0` chunk, recomputing the container
2052hash. A host that takes them (Windows 11) gets one call and its own blob back. `d3d12_xs_root_signature_test` covers
2053both descriptor versions and checks the flags through the host deserializer and a device; the test-side
2054`d3d12test::serialize_root_signature` helper does the same retry for tests that serialize directly.
2055
2045Things that can invalidate this simple model, all **Open**: 2056Things that can invalidate this simple model, all **Open**:
2046 2057
2047- **Shader visibility.** The layer starts with one global block in root-parameter order and treats visibility as 2058- **Shader visibility.** The layer starts with one global block in root-parameter order and treats visibility as