diff options
Diffstat (limited to 'docs/d3d12_vulkan.md')
| -rw-r--r-- | docs/d3d12_vulkan.md | 32 |
1 files changed, 17 insertions, 15 deletions
diff --git a/docs/d3d12_vulkan.md b/docs/d3d12_vulkan.md index 6834672b7..3f165ab3e 100644 --- a/docs/d3d12_vulkan.md +++ b/docs/d3d12_vulkan.md | |||
| @@ -2030,16 +2030,21 @@ Implemented (`QueryHeap` in `runtime/shims/d3d12_vulkan_device.cpp`, the query c | |||
| 2030 | overwrites can be recorded before the earlier commands complete. `vk_overlapping_occlusion` checks crossing | 2030 | overwrites can be recorded before the earlier commands complete. `vk_overlapping_occlusion` checks crossing |
| 2031 | and nested scopes, more than one scratch chunk, alternating binary and ordinary resolves under a predicate, | 2031 | and nested scopes, more than one scratch chunk, alternating binary and ordinary resolves under a predicate, |
| 2032 | and gated submissions on a GPU. | 2032 | and gated submissions on a GPU. |
| 2033 | - **Resolves during a pipeline-statistics query** (D3D-162). The helper dispatches above (binary normalisation, | 2033 | - **Helper dispatches during a pipeline-statistics query** (D3D-162). The helper dispatches above (binary |
| 2034 | occlusion sums) and the statistics sum below would count in the application's `CSInvocations` if they ran inside | 2034 | normalisation, occlusion sums), statistics sums, `SetPredication` captures, predicated buffer copies and D24/RGB96 footprint |
| 2035 | its query. So a statistics query that contains a resolve other than a timestamp copy is split. Its counters go to | 2035 | conversions would count in the application's `CSInvocations` if they ran inside its query. Such a query is split. |
| 2036 | physical `PIPELINE_STATISTICS` segments in a pool of the submission's own; a segment ends before each such resolve | 2036 | Its counters go to physical `PIPELINE_STATISTICS` segments in a pool of the submission's own; a segment ends |
| 2037 | and a new one begins after it. Its result is the sum of its segments, added per counter by a compute dispatch | 2037 | before each helper and a new one begins after it. Non-query helpers and resolves share the segment numbering. |
| 2038 | (`statistics_sum.comp`) on the same scratch buffer, which is itself kept out of any statistics query still running. | 2038 | Its result is the sum of its segments, added per counter by a compute dispatch (`statistics_sum.comp`) on the |
| 2039 | same scratch buffer, which is itself kept out of any statistics query still running. | ||
| 2039 | Whether a resolve dispatches is only known once the list is planned against the heaps, so every such resolve | 2040 | Whether a resolve dispatches is only known once the list is planned against the heaps, so every such resolve |
| 2040 | splits the query. `vk_binary_occlusion` checks that a binary resolve and a statistics sum inside statistics queries | 2041 | splits the query. `vk_binary_occlusion` checks that a binary resolve and a statistics sum inside statistics queries |
| 2041 | leave every counter at 0. `vk_overlapping_occlusion` puts a native draw in each segment and checks the split sums | 2042 | leave every counter at 0. `vk_overlapping_occlusion` puts a native draw in each segment and checks the split sums |
| 2042 | against unsplit queries with the same draws, word by word. | 2043 | against unsplit queries with the same draws, word by word. `vk_predicated_copy` checks captures, rebindings and |
| 2044 | predicated copies; `depth24_convert` checks both conversion directions for D24 and RGB96. Their byte-exact | ||
| 2045 | results still match and all 11 statistics counters are zero. Without a statistics pool (single-list `replay()` or | ||
| 2046 | a queue without the summation helper), these three commands are refused before helper scratch allocation or | ||
| 2047 | recording. The resolve fallback is unchanged: only resolves needing dispatches are refused there. | ||
| 2043 | - **Timestamps.** `GetTimestampFrequency` is `1e9 / timestampPeriod` (1 GHz on the test GPU). Every D3D12 queue | 2048 | - **Timestamps.** `GetTimestampFrequency` is `1e9 / timestampPeriod` (1 GHz on the test GPU). Every D3D12 queue |
| 2044 | shares one `VkQueue` for now (question 12), so they share one frequency. | 2049 | shares one `VkQueue` for now (question 12), so they share one frequency. |
| 2045 | 2050 | ||
| @@ -2047,10 +2052,6 @@ Not implemented yet: | |||
| 2047 | 2052 | ||
| 2048 | - **Overlapping queries.** Replay refuses overlapping pipeline-statistics queries or occlusion overlaps involving | 2053 | - **Overlapping queries.** Replay refuses overlapping pipeline-statistics queries or occlusion overlaps involving |
| 2049 | a binary query with `ReplayResult::unsupported`. | 2054 | a binary query with `ReplayResult::unsupported`. |
| 2050 | - **Other helper dispatches during a pipeline-statistics query.** Replay still refuses `SetPredication` and | ||
| 2051 | predicated copies and D24/RGB96 footprint conversions while pipeline statistics are active, since their | ||
| 2052 | dispatches would change the reported compute-invocation count. The single-list `replay()` helper, which has no | ||
| 2053 | segment pool, keeps refusing the occlusion resolves above that need a dispatch there. | ||
| 2054 | - Stream-output and mesh-shader statistics. (`GetClockCalibration` is implemented: see section 4.4, "Fences, | 2055 | - Stream-output and mesh-shader statistics. (`GetClockCalibration` is implemented: see section 4.4, "Fences, |
| 2055 | queues and frames in flight".) | 2056 | queues and frames in flight".) |
| 2056 | - Xbox-specific query heap types (if any) are **Open**; unknown types are logged. | 2057 | - Xbox-specific query heap types (if any) are **Open**; unknown types are logged. |
| @@ -2091,9 +2092,9 @@ Not implemented yet: | |||
| 2091 | CPU readback or per-predicate wait is used. This helper requires a compute-capable configured queue family; | 2092 | CPU readback or per-predicate wait is used. This helper requires a compute-capable configured queue family; |
| 2092 | unsupported queues fail preparation instead of falling back to the low word. The synthetic GLSL source and | 2093 | unsupported queues fail preparation instead of falling back to the low word. The synthetic GLSL source and |
| 2093 | embedded SPIR-V are shipped together; normal builds do not need a shader compiler. | 2094 | embedded SPIR-V are shipped together; normal builds do not need a shader compiler. |
| 2094 | Capturing a new predicate inside an active pipeline-statistics query is rejected as unsupported, because the | 2095 | Capturing a new predicate inside an active pipeline-statistics query splits the query around the capture |
| 2095 | helper's compute invocation would otherwise pollute the application's result; capturing before the query is | 2096 | dispatch (D3D-162, section 4.6), keeping its invocation out of the application's result. Without a statistics |
| 2096 | allowed. Virtualising that query is not part of this change. | 2097 | segment pool, preparation still refuses the capture before allocating its scratch. |
| 2097 | Integration notes for #291 and D3D-27: the capture helper binds its own compute pipeline, descriptor set 0 | 2098 | Integration notes for #291 and D3D-27: the capture helper binds its own compute pipeline, descriptor set 0 |
| 2098 | and push constants. The compute path must restore those bindings afterward, or bind its application state | 2099 | and push constants. The compute path must restore those bindings afterward, or bind its application state |
| 2099 | before each dispatch. Copies and compute dispatches cannot execute inside dynamic rendering, so render-pass | 2100 | before each dispatch. Copies and compute dispatches cannot execute inside dynamic rendering, so render-pass |
| @@ -2112,7 +2113,8 @@ Not implemented yet: | |||
| 2112 | for ordinary copies; mixed lists accumulate both before main's queue-specific host-stage filtering. | 2113 | for ordinary copies; mixed lists accumulate both before main's queue-specific host-stage filtering. |
| 2113 | This helper also binds compute pipeline/set 0/push constants, so the | 2114 | This helper also binds compute pipeline/set 0/push constants, so the |
| 2114 | application-state restoration requirement above applies. A predicated copy inside an active pipeline-statistics | 2115 | application-state restoration requirement above applies. A predicated copy inside an active pipeline-statistics |
| 2115 | query is rejected to avoid counting internal compute work. | 2116 | query splits that query around the helper dispatches (D3D-162); without a statistics segment pool it is refused |
| 2117 | before copy scratch allocation. | ||
| 2116 | Synthetic checks: `predicated_copy_test` covers preparation and rejection paths without a GPU; | 2118 | Synthetic checks: `predicated_copy_test` covers preparation and rejection paths without a GPU; |
| 2117 | `d3d12_predicated_copy_test` compares 180 byte-exact cases against WARP and an independent literal oracle, | 2119 | `d3d12_predicated_copy_test` compares 180 byte-exact cases against WARP and an independent literal oracle, |
| 2118 | plus 16 query-to-copy cases: real empty ordinary/binary occlusion queries resolve zero into a default-heap | 2120 | plus 16 query-to-copy cases: real empty ordinary/binary occlusion queries resolve zero into a default-heap |