Explore: separate cull scratch buffers for the shadow and mirror culls so the RT-build join can move later (more async overlap) #633

Open
opened 2026-10-10 09:27:32 +00:00 by sky_line · 0 comments
Owner

Exploration. Proposed by the 2026-10-10 GPU pipeline audit; not yet implemented.

Idea

The shadow and mirror culls share the cull scratch buffers (cand / cand_meta) with other culls. Because of that, the async RT build has to be joined before the shadow rigged cull. Giving the shadow and mirror culls their own scratch buffers would let the join move to the first TLAS reader in pass 1b, so the RT build overlaps the prepass instead of making graphics wait for it.

Why

About 0.3 ms of q_rt_build likely shows up today as graphics waiting behind it during the prepass (measured 2026-10-10: q_rt_build ~1.3-1.4 ms; q_async_span 5.1 ms against q_async_busy 2.8 ms). It changes no pixels, only overlap.

Cost and risk

  • Extra VRAM for the duplicate scratch buffers; size them from the existing high-water marks, not the worst case.
  • Re-check every reader of the TLAS before pass 1b (probe traces, now also on the async queue; shadow RT) and the join barriers.
  • Validate with synchronization validation on.

Measure

GPU sub ms/frame total= and q_async_span against q_async_busy, in the same sim, before and after.

Related: #256, the roadmap's overlap/async-compute phase.

**Exploration.** Proposed by the 2026-10-10 GPU pipeline audit; not yet implemented. ## Idea The shadow and mirror culls share the cull scratch buffers (`cand` / `cand_meta`) with other culls. Because of that, the async RT build has to be joined before the shadow rigged cull. Giving the shadow and mirror culls their own scratch buffers would let the join move to the **first TLAS reader in pass 1b**, so the RT build overlaps the prepass instead of making graphics wait for it. ## Why About 0.3 ms of `q_rt_build` likely shows up today as graphics waiting behind it during the prepass (measured 2026-10-10: `q_rt_build` ~1.3-1.4 ms; `q_async_span` 5.1 ms against `q_async_busy` 2.8 ms). It changes no pixels, only overlap. ## Cost and risk - Extra VRAM for the duplicate scratch buffers; size them from the existing high-water marks, not the worst case. - Re-check every reader of the TLAS before pass 1b (probe traces, now also on the async queue; shadow RT) and the join barriers. - Validate with synchronization validation on. ## Measure GPU sub ms/frame `total=` and `q_async_span` against `q_async_busy`, in the same sim, before and after. Related: #256, the roadmap's overlap/async-compute phase.
sky_line added this to the Slipstream project 2026-10-10 09:27:32 +00:00
Sign in to join this conversation.
No milestone
No project
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.

Dependencies

No dependencies set.

Reference
sky_line/Slipstream#633
No description provided.