diff options
| author | Jan Trencansky <jan.trencansky@protonmail.com> | 2026-11-27 06:27:01 -0500 |
|---|---|---|
| committer | Jan Trencansky <jan.trencansky@protonmail.com> | 2026-11-27 06:27:01 -0500 |
| commit | 3c9820f8daae7e478cdca7f7e1d395e60d7c4ddf (patch) | |
| tree | 80db1c1f5f61423e7a7ea0290b3ca5a1596e995e /docs/d3d12_vulkan.md | |
| parent | b67ef5e17ce837828f454e62fad373163d220570 (diff) | |
| parent | be3e9c1424c852d6248a625e68b66bc45d24ed23 (diff) | |
Local test merge: bindless index in dword 6 of heap T#s, read directly by placed operands (be3e9c142)
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Diffstat (limited to 'docs/d3d12_vulkan.md')
| -rw-r--r-- | docs/d3d12_vulkan.md | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/docs/d3d12_vulkan.md b/docs/d3d12_vulkan.md index 377358b50..8cd67224d 100644 --- a/docs/d3d12_vulkan.md +++ b/docs/d3d12_vulkan.md | |||
| @@ -2215,7 +2215,9 @@ The layer's descriptor model: | |||
| 2215 | which is the assumption to verify. If it uses an opaque format, the layer must translate at bind time. | 2215 | which is the assumption to verify. If it uses an opaque format, the layer must translate at bind time. |
| 2216 | - At execution, for each bound table (or the whole bound heap when direct indexing is enabled), the layer walks | 2216 | - At execution, for each bound table (or the whole bound heap when direct indexing is enabled), the layer walks |
| 2217 | the declared descriptor range with the heap's stride, parses each T#/S#, and ensures a bindless entry exists: | 2217 | the declared descriptor range with the heap's stride, parses each T#/S#, and ensures a bindless entry exists: |
| 2218 | - image T# → `VkImageView` (format, view type, mip range, array layers) → bindless image index; | 2218 | - image T# → `VkImageView` (format, view type, mip range, array layers) → bindless image index, which the layer |
| 2219 | writes into dword 6 of the T# where shaders read it (the console heap copy's slot, or the layer's own heap), with | ||
| 2220 | the arrays it is bound in (`docs/design.md`, "Bindless index in the T#"); the hash table keeps the key as written; | ||
| 2219 | - sampler S# → `VkSampler` (filter, address modes, LOD, compare, anisotropy) → bindless sampler index; | 2221 | - sampler S# → `VkSampler` (filter, address modes, LOD, compare, anisotropy) → bindless sampler index; |
| 2220 | - buffer V# / CBV → no Vulkan view; the descriptor already contains a console VA the shader dereferences. | 2222 | - buffer V# / CBV → no Vulkan view; the descriptor already contains a console VA the shader dereferences. |
| 2221 | - **Buffer UAVs.** `CreateUnorderedAccessView` on a buffer writes a V# in the first 16 bytes of the slot (the rest of | 2223 | - **Buffer UAVs.** `CreateUnorderedAccessView` on a buffer writes a V# in the first 16 bytes of the slot (the rest of |
| @@ -4781,6 +4783,12 @@ store, load, mesh, geometry and BVH tests; this layer is the other half. | |||
| 4781 | 4783 | ||
| 4782 | ### 5.1 Descriptor hash table details | 4784 | ### 5.1 Descriptor hash table details |
| 4783 | 4785 | ||
| 4786 | Since the T# index word (`docs/design.md`, "Bindless index in the T#") the table serves only what the word does not | ||
| 4787 | reach: every S#, and the T#s a translated module cannot trace to a heap slot (1,062 of the 439,415 T# operands of | ||
| 4788 | the 1.0.2.1 corpus, in 108 modules). A T# loaded from a heap the layer writes carries its index and kind in dword 6 | ||
| 4789 | and is never looked up. Every T# key is still inserted, as the title wrote it: a T# outside the heaps is found by | ||
| 4790 | those words. | ||
| 4791 | |||
| 4784 | The exact layout the shader reads (from `tools/rdna2spirv.py`, `desc_lookup`): | 4792 | The exact layout the shader reads (from `tools/rdna2spirv.py`, `desc_lookup`): |
| 4785 | 4793 | ||
| 4786 | ``` | 4794 | ``` |