RUNTIME 2314: A host step's rate-map probe runs in parts, each on the GPU while the host records the next
A rate-mapped pass whose records the GPU may write is recorded by a host step that fans its triangles out to the map's regions after a probe: every command's draw recorded once more through the probe variant, submitted, and waited for before the routes are recorded. The host recorded the whole probe with the GPU idle, then sat idle itself for the probe's whole GPU time. On a 3D renderer's frame on an RTX 3090 (pin 91b) that wait was 23-35% of host_step_nanos, 5-7 ms of a ~22 ms step, three steps a frame. Now the probe is recorded in parts: at least 32 commands a part and at most 8 parts a probe (DeferredPass::probe_parts). Each part is submitted with its own fence once recorded, so the GPU runs it while the host records the next, and the host waits once, for every fence, after the last part (CommandBuffer::submit_fenced / wait_fenced, the halves of rerun::submit_waited, which the predicated loop's runs again keep using). A part may hold commands of several executions; its draws take the flag words one recording would give them (the index carried from part to part, each command's slot by its place among its execution's commands that run), so the probe's words, the routes and the pixels are the same in any parts. A probe that stops (a barrier, a draw that writes memory) stops for the rest of its execution; a part recorded in more than one run sends the execution region by region, as one recording did. Every part submitted is waited for before the step goes on, a failed later recording's too. Ordering: the parts go on the command buffer's own VkQueue, in order, and each part's primary begins with the segment's full barrier (EncoderCore::segment), as the one probe's did, so part k+1 follows part k and the pass follows the last; no semaphore and no other queue's edge is added. Cost: up to 7 more submissions and probe render pass instances a step (load and store in GENERAL, no fragment). WorkCounts::rate_map_probe_parts counts the parts; rate_map_probes stays one a step; rate_map_probe_gpu_nanos sums the parts' times; rate_map_probe_wait_nanos is now the host's one wait after the last part. Test: tests::rate_mapped_fan_out's a_host_step_probes_many_commands_in_parts: 72 commands (the eight's pattern nine times) probe in 3 parts with the same flagged, fanned-out and parted draws, each 9 times the eight's, and the encoder's pixels; the eight-command test asserts one part. The workload takes its command count. New WorkCounts field: rate_map_probe_parts (api_signatures blessed). No new Degradation kind. No RUNTIME_VERSION bump (main does it at landing). Also in this landing: the icb_reads example's --rate-map and --wide-every W (the A/B shape); the parts' recordings joined once, after the wait; and the split fenced wait reaching the device's functions inside each exit-guard section (a predicated loop's run again on the loop thread). RUNTIME_VERSION moves: a host step's probe of an unchanged artifact is now recorded and submitted in parts. Verified (lane icbstep2, msi lavapipe): - m3-max-30234 at c41586a13d: clippy -D warnings plain and cpu_icd (runtime, all targets, all features) exit 0; 63/63 for rate_map|rerun_arenas|indirect_command_buffer|icb_|host_step| fan_out, among them the ordering tests a_flagged_draw_s_parts_take_each_triangle_once_in_order, a_host_step_s_instances_follow_their_commit_in_the_program_s_order, a_recovery_s_carry_waits_for_a_write_without_the_lock and an_unshared_head_at_its_host_step_goes_before_work_whose_room_came_after_its_commit; the new a_host_step_probes_many_commands_in_parts reports probes [1,36,36,36], 3 parts and 5 submissions, with the encoder's pixels. - Negative control m3-max-30241 (one part a probe): the new test fails, "the probe's parts of 32, 32 and 8 commands, left: 1 right: 3", with the same probe counts. Expected, not yet measured: the 3090 release A/B (host_step_nanos and rate_map_probe_wait_nanos a step) follows. The consumer's renderer run at the next pin is the workload proof.
This commit is contained in:
1 parent
f3a2ff76f7
commit
744dfd4d9d
9 files changed
+493
-145
No files matched your search
+6
-3
@@ -6178,9 +6178,12 @@ each item named states the rule in full.
|
||||
position and a depth `Equal` test across them holds where both pipelines compute the position
|
||||
alike; a draw the variant does not take is drawn through each region's viewport
|
||||
(`docs/FAST-PATHS.md`, known gaps). The
|
||||
probe costs the host step a submission it waits for before the pass, which runs each probed
|
||||
draw's vertex function and geometry stage once and shades nothing (`WorkCounts::rate_map_probes`,
|
||||
`rate_map_probe_gpu_nanos`, the host's wait `rate_map_probe_wait_nanos`); a fanned-out draw
|
||||
probe costs the host step submissions it waits for before the pass, which run each probed
|
||||
draw's vertex function and geometry stage once and shade nothing: its parts, of at least 32
|
||||
commands and at most 8 a probe, each submitted once the host recorded it, so the GPU runs one
|
||||
while the host records the next, and one wait after the last (`WorkCounts::rate_map_probes`,
|
||||
`rate_map_probe_parts`, `rate_map_probe_gpu_nanos`, the host's wait
|
||||
`rate_map_probe_wait_nanos`); a fanned-out draw
|
||||
runs its vertex function once where region by region it runs once per region
|
||||
(`rate_mapped_pass.rs`, **Fan-out**).
|
||||
- **A pass over a map of a zero screen extent is refused**, `RegionError::RegionExtent` on that
|
||||
|
||||
Reference in new issue
Block a user