Skip to content

Vulkan: allocate fewer command buffers for small encoders - #6

Draft
matthargett wants to merge 1 commit into
trunkfrom
perf/vulkan-initial-command-pool
Draft

matthargett wants to merge 1 commit into
trunkfrom
perf/vulkan-initial-command-pool

Conversation

@matthargett

Copy link
Copy Markdown
Member

Potential upstream optimization; no XR or Babylon dependency. Initially allocate two buffers per command pool instead of sixteen. Keep the existing batch size when more are needed. Reset and retirement are unchanged.

Quest 1 Vulkan, two finished commands per submit, exact GPU readbacks every 12 iterations. A cache-miss call graph led through command-pool reset into the driver allocator. Matched Release ABBA, three nonmultiplexed counter groups: CPU cycles −10.2%, instructions −7.9%, L1 data misses −16.5%, branch misses −6.2%; median submit 139.75 → 137.08 µs. Two runs per variant per group. In four placed Hill Valley windows without capture, 5.00 → 5.06 app fps; no meaningful scene uplift.

The grow/discard/reset sequence (0–48 finished buffers) passed on Quest Vulkan; the registered GPU test type-checks on this branch. Both physical comparisons used the Babylon integration with wgpu 30.0.1.

  • Compare command-heavy workloads on additional vendors before proposing upstream.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant