Skip to content

feat(agc): GPU descriptor heap on VK_EXT_descriptor_heap (APS5_GPU_HEAP) - #106

Open
Thimo188 wants to merge 333 commits into
mainfrom
upstream-pr/9508
Open

Thimo188 wants to merge 333 commits into
mainfrom
upstream-pr/9508

Conversation

@Thimo188

@Thimo188 Thimo188 commented Dec 2, 2026

Copy link
Copy Markdown
Owner

Imported from boykopovar/AnyPS5#9508, originally opened by Raghav314.

Source commit: 7d4214c1f1f72298f18d204218b15d6f2d6fa945. The import branch preserves this fetched upstream PR snapshot. The description and validation below are copied from upstream; no new code changes or test runs were made for this import. Original reviews, discussions, and attachments remain at the linked upstream PR.


What

An opt-in GPU descriptor heap, APS5_GPU_HEAP=1, built on VK_EXT_descriptor_heap. Draws and dispatches stop rebuilding and binding descriptor sets on the CPU. It builds on the draw pipeline (boykopovar#6946, merged) and replaces boykopovar#6947, which is closed.

  • One binding model. With the heap on, every stage of every draw and dispatch takes the heap; the per-draw path exists only with the heap off. Each draw and dispatch is decided once, before any stage is built, from its stages' resource plans. There is no mixed-draw retry, refused pair or per-shader verdict, and any draw or dispatch that would need a per-draw fallback is treated as a heap bug, to be fixed in the heap. A stage the heap can't take fails with an error that names the slot count or the unmapped binding. APS5_GPU_HEAP_EXCLUDE is the only way to send a stage per-draw with the heap on, as a debug aid.
  • Heaps. One resource heap and one sampler heap (2048 slots, D3D12's limit), in device-local host-visible memory when the device has it. The shared image slot pool holds 233415 slots after the 57 each binding kind reserves for its absent descriptor, and grows into the rest of the resource heap, up to 524231 (APS5_HEAP_SLOT_CAP). Its length reaches shaders as a specialization constant, the way vkd3d-proton sizes its heap arrays at pipeline creation.
  • Slot lifetime. Slots are a cache of descriptors whose owners are still alive. Image and sampler slots no draw has used for two submissions are evicted, and a nearly full heap submits the open batch at the next draw or dispatch and evicts the least recently used slots. An evicted slot is handed out again only after the submission that covers it completes, so the heap needs timeline semaphores (APS5_NO_TIMELINE with APS5_GPU_HEAP fails at device creation).
  • Stage tables. Like vkd3d-proton's descriptor tables, a heap stage's resolved state outlives the draw: its image slots are taken once per stage result, and its finished shader data (walked words, data patches, slot indices), flattened SRT and image table map live in persistent tables owned by the stage result, retired after the last batch that read them. The image table map is checked against slot generations instead of being rebuilt. The bindings each stage owns and its addressed buffer elements are listed once, when the resources are built, as vkd3d-proton records its root descriptor and table masks at root signature creation.
  • Root, user and shader data. Like a vkd3d-proton root signature, a graphics pipeline gets one push layout for all its stages: the driver packs the root items its stages read (pagetable, fault and GDS addresses, stencil reference, each stage's data and user-data addresses) and each stage's hottest words into the 64 push dwords, and passes the positions as specialization constants. A stage's user-data words live in their own per-draw block with its own root address, the way the PS5 delivers user SGPRs and vkd3d-proton gives per-draw constants a root CBV: fully pushed user words write no block, and a draw that changes only user words keeps the data block. The rest goes into an upload pool of 2 MiB blocks, like vkd3d-proton's uniform upload pool, read through addresses pushed per draw. A batch takes new blocks instead of waiting, and idle blocks over 32 MiB are freed.
  • Buffers. Like vkd3d-proton's root descriptors, a heap stage passes its guest buffers as addresses in the pipeline's push layout, on every vendor: up to four records of 64-bit address and byte size per stage, mapped as storage buffers with VK_DESCRIPTOR_MAPPING_SOURCE_PUSH_ADDRESS_EXT. The size keeps the PS5's bounds rule (out-of-range loads read zero), which D3D12 root descriptors don't have. Buffers past four, or past the room left in the push data, go to a per-draw overflow block read by address. A buffer the stage only reads with scalar loads at constant offsets, within 64 KiB, is mapped as a uniform buffer, as vkd3d-proton maps root CBVs, when the device has uniformBufferStandardLayout and a uniform offset alignment of at most 256. Buffer addresses come from where the buffers are made, as vkd3d-proton keeps a resource's VA, so no draw asks the driver for one. The driver writes no buffer descriptors per draw, and the resource heap holds only image slots. Heap stages of address-based draws read guest memory in place, as the BDA table and the hardware do.
  • Samplers. A sampler whose words are constants in the shader code is embedded in the pipeline's descriptor mapping (pEmbeddedSampler), as vkd3d-proton maps static samplers, deduplicated across pipelines. Past the device's maxDescriptorHeapEmbeddedSamplers it reads a sampler heap slot at a fixed offset.
  • Images. A stage whose images all come from descriptors is recompiled in GPU mode (gpuResolvedImages): its image metadata names the binding element, and the driver writes the resolved heap slots into its shader data. Covered: sampled and storage images and samplers; image, storage image and sampler tables, image atomics through tables included; color target merges; dynamic-resolution image table variants.
  • Compute and internal passes. Compute dispatches, including indirect dispatches with thread dimensions, take the heap. The driver's own passes (color transfer, multisample readback and upload, staged merge, depth to storage, first-sample copy, sample order, the detiler's buffer detile and repack, the presentation pass, the FSR upscaler, indirect argument checks) have heap twin pipelines with a null layout and take parameters through vkCmdPushDataEXT, like vkd3d-proton's meta shaders, so they don't put the command buffer back in classic descriptor mode.
  • Reuse.
    • A heap stage keeps one compiled template per binding plan shape, and each draw carries its own descriptor words (HeapStageWords), filled straight from the draw's words. Templates are kept within APS5_HEAP_TEMPLATE_MIB and found through a per-thread front table.
    • A heap image slot is copied from the view's already encoded descriptor instead of calling vkWriteResourceDescriptorsEXT again (keyed by view, layout and kind, with a generation check), as vkd3d-proton copies CPU descriptors.
    • Cached heap draws get draw recipes, including draws whose read-only buffers or user-data V#s moved; the recipe redoes the moved-buffer check at each hit and pushes the moved buffers' addresses. A relocated heap draw patches its per-draw ring words instead of copying its program.
    • An address-based draw whose BDA accesses only read reuses its address space within the collect epoch.
    • Caches that cost as much as they saved, each benched off on its own, were removed: the heap walk memo, the stage skip, the BDA root-role memo and the pushed-range cache. APS5_HEAP_NO_CACHE=all|heap|<name>,... bypasses the remaining heap and shared draw caches by name.
  • Pipeline journal and replay. The journal knows the heap layouts, so GPU-mode pipelines are replayed on the next run. agc_shader_replay keeps a captured request's heap profile, and --gpu-heap / --no-gpu-heap override it.
  • Without the extension, or on a device whose heaps can't hold the slots, every stage takes the existing per-draw path, so lavapipe CI and other drivers are unaffected. The heap also stays off, with one log line, when the driver's VK_EXT_descriptor_heap is an older revision than the released one (specVersion below VK_EXT_DESCRIPTOR_HEAP_SPEC_VERSION; a pre-release revision crashed every heap test on an earlier 595.99.02 build, and 595.99.02 now runs the heap), or when VK_LAYER_KHRONOS_validation older than 1.4.363 is enabled (older layers check heap push data against the pre-heap rules).
  • Vulkan-Headers goes to 1.4.340, the first release with VK_EXT_descriptor_heap.
  • Changes with the heap off. Four changes also apply with APS5_GPU_HEAP unset:
    • A storage image whose DCC keys moved is refreshed in place instead of leaving the fast proof path; APS5_NO_OWN_IMAGE_REFRESH turns this off.
    • A draw recipe hit touches the resource cache's LRU order, and takes its lock, only when its entry was not touched within the last eighth of the cache's capacity.
    • The request serializer writes version 60 for every request; it carries this PR's fields after main's. Version 57 reads as main's layout, and 58 and 59 as this branch's.
    • Pipeline layouts set VK_PIPELINE_LAYOUT_CREATE_INDEPENDENT_SETS_BIT_EXT only when the graphics pipeline library is in use. The flag is invalid without that feature (VUID-VkPipelineLayoutCreateInfo-graphicsPipelineLibrary-06753), and only pipelines linked from libraries read it.

APS5_VERIFY_GPU_HEAP=1 checks heap slots against the bound textures, images and views and the GPU-read constants, rebuilds 1 in N GPU-mode stages on the per-draw path and compares them, compares pushed ranges and relocated ring hits, and throws at the draw when anything differs. APS5_GPU_HEAP_EXCLUDE sends stage classes (compute, pixel, ..., tables, storage, sampled) to the per-draw path while the heap stays on, for bisecting. APS5_PIPELINE_STATS=2 adds a [gpu-heap] line every 10 s with heap and plain draws and dispatches, data pool MiB written, and slots held, evicted and waited for.

PPSA36082 (Hades II)

Title and scene: PPSA36082 (Hades II) 01.006.000, the hub (Crossroads), player standing still, 1920x1080, APS5_TRACE_SECONDS=60:10. Captured as the Performance report form describes: same machine, scene and settings, in one session on 2026-10-31, main first; caches warm (each build ran once into the hub and the title was restarted before its captures; no shader cache file was written during any capture); no other APS5_TRACE_* or APS5_PROFILE_* switch; log not redirected (each capture ran in its own terminal window). All with APS5_PIPELINED_DRAWS=32 APS5_PIPELINE_DISPATCH=1. Every build had its submodules at their pins ("dirty":false).

Current main still stops Hades II while the hub loads (native multisample depth metadata fill transition is not implemented, then external GPU writes over native multisample depth are not implemented with boykopovar#6300 alone). boykopovar#9533 (EagleBearerYS) fixes both, so both builds have boykopovar#9533 (dcf420e) merged locally, without conflicts:

presents / 10 s frame p50 p90 p99 GPU busy per present queue worker busy
main 0835ec8 + boykopovar#9533, APS5_DRAW_PIPELINE=1 952 10.41 ms 11.20 ms 12.26 ms 2.34 ms 97%
this PR 95e1f33 + boykopovar#9533, APS5_DRAW_PIPELINE=1 APS5_GPU_HEAP=1 1032 9.55 ms 10.73 ms 11.94 ms 2.29 ms 96%
main 0835ec8 + boykopovar#9533 (no draw pipeline) 902 11.02 ms 11.79 ms 12.95 ms 2.44 ms 97%

The first two rows are the comparison (same draw pipeline, captured back to back): with the heap the frame p50 is 8% lower and presents 8% higher. The GPU is busy about 2.3 ms of a 10 ms frame in all of them: Hades II is bound by the queue worker recording draws, which is what the heap shortens. The third row is main with its default settings, for reference.

Changes since the Hades II capture

The captures ran on 95e1f33. The head adds, besides merges of main:

  • heap stages keep their tables across draws: image slots are taken once per stage result, and its shader data, flattened SRT and image table map live in persistent tables; the walk memo, the stage skip, the BDA root-role memo and the pushed-range cache are deleted (7035a25);
  • heap stages read their user data from a per-draw user block (4c2a741, runtime ABI 17);
  • lighter per-draw heap work on the committer: bindings laid out when resources are built (b385f6b), buffer addresses carried from where buffers are made (0c27c51), push data copied in runs with binary-searched address overrides (1bedba2, 0433c01), a stage's user block reused when its inputs did not change (b92b489), a per-thread template front table (af655a4), relocated heap draws patching their ring words (f208a02);
  • pending storage images found through a sorted range index, with a lock-free check when nothing pending is near (c9a4ea4 to bf28d72, 7a3eecf);
  • pipelined dispatches and sample-count dumps queue behind the draw finisher instead of draining it (5204b8a);
  • the FSR upscaler draws through the heap (bcd73c1), and shader request dumps are written for heap draw stages (fd6cf2c).

Hades II has not been recaptured on the head.

Summary lines

main 0835ec8 + boykopovar#9533, APS5_DRAW_PIPELINE=1

{"commit":"9837bacfcdac","dirty":false,"env":{"APS5_DRAW_PIPELINE":"1","APS5_PIPELINED_DRAWS":"32","APS5_PIPELINE_DISPATCH":"1","APS5_TRACE_DIR":"<path>","APS5_TRACE_SECONDS":"60:10"},"gpu":"NVIDIA GeForce RTX 4090","driver":"NVIDIA 615.78.08","os":"Linux 7.3.0-3-cachyos","cpu":"AMD Ryzen 7 7800X3D 8-Core Processor","cpu_threads":16,"memory_mib":31742,"title_id":"PPSA36082","title":"Hades II","content_version":"01.006.000","resolution":"1920x1080","window":{"spec":"seconds 60:10","first_present":5794,"ms":10004.558},"presents":952,"frame_ms":{"p50":10.414,"p90":11.198,"p99":12.259,"max":13.377},"gpu_busy_ms_per_present":2.344,"worker_busy_pct":{"queue worker 0x0":96.595},"top_phases_ms_per_frame":{"Driver.Packet":10.142,"Driver.Packet.draw":7.277,"Graphics.Draw":7.264,"Driver.Draw":7.206,"Driver.DrawFinish":6.438,"Graphics.Draw.draw_and_resource_release":6.036,"Driver.Draw.prepare":4.157,"Driver.DrawFinish.shader_compile_and_link":3.928},"trace_dropped":false,"trace":"aps5-trace-9837bacfcdac-823993.json.gz"}

this PR 95e1f33 + boykopovar#9533, APS5_DRAW_PIPELINE=1 APS5_GPU_HEAP=1

{"commit":"37724aa7680e","dirty":false,"env":{"APS5_DRAW_PIPELINE":"1","APS5_GPU_HEAP":"1","APS5_PIPELINED_DRAWS":"32","APS5_PIPELINE_DISPATCH":"1","APS5_TRACE_DIR":"<path>","APS5_TRACE_SECONDS":"60:10"},"gpu":"NVIDIA GeForce RTX 4090","driver":"NVIDIA 615.78.08","os":"Linux 7.3.0-3-cachyos","cpu":"AMD Ryzen 7 7800X3D 8-Core Processor","cpu_threads":16,"memory_mib":31742,"title_id":"PPSA36082","title":"Hades II","content_version":"01.006.000","resolution":"1920x1080","window":{"spec":"seconds 60:10","first_present":6131,"ms":10008.044},"presents":1032,"frame_ms":{"p50":9.552,"p90":10.734,"p99":11.937,"max":13.199},"gpu_busy_ms_per_present":2.285,"worker_busy_pct":{"queue worker 0x0":96.278},"top_phases_ms_per_frame":{"Driver.Packet":9.327,"Driver.Packet.draw":6.576,"Driver.Draw":6.507,"Driver.DrawFinish":6.079,"Graphics.Draw":6.022,"Graphics.Draw.draw_and_resource_release":4.888,"Driver.DrawFinish.shader_compile_and_link":4.021,"Driver.Draw.prepare":3.902},"trace_dropped":false,"trace":"aps5-trace-37724aa7680e-824541.json.gz"}

main 0835ec8 + boykopovar#9533 (no draw pipeline)

{"commit":"9837bacfcdac","dirty":false,"env":{"APS5_PIPELINED_DRAWS":"32","APS5_PIPELINE_DISPATCH":"1","APS5_TRACE_DIR":"<path>","APS5_TRACE_SECONDS":"60:10"},"gpu":"NVIDIA GeForce RTX 4090","driver":"NVIDIA 615.78.08","os":"Linux 7.3.0-3-cachyos","cpu":"AMD Ryzen 7 7800X3D 8-Core Processor","cpu_threads":16,"memory_mib":31742,"title_id":"PPSA36082","title":"Hades II","content_version":"01.006.000","resolution":"1920x1080","window":{"spec":"seconds 60:10","first_present":5563,"ms":10006.024},"presents":902,"frame_ms":{"p50":11.019,"p90":11.793,"p99":12.945,"max":15.162},"gpu_busy_ms_per_present":2.436,"worker_busy_pct":{"queue worker 0x0":97.470},"top_phases_ms_per_frame":{"Driver.Packet":10.801,"Driver.Packet.draw":9.072,"Driver.Draw":8.983,"Graphics.Draw":7.347,"Graphics.Draw.draw_and_resource_release":6.089,"Driver.Draw.shader_compile_and_link":5.295,"Shader.DrawStage":3.481,"Shader.DrawStage.capture_resources":1.745},"trace_dropped":false,"trace":"aps5-trace-9837bacfcdac-821781.json.gz"}

Traces:

Digests (python3 tools/trace_digest.py <trace>)

`main` 0835ec8 + boykopovar#9533, `APS5_DRAW_PIPELINE=1`

seconds 60:10 from present 5794: 952 presents, frame p50 10.4 / p90 11.2 / p99 12.3 / max 13.4 ms, GPU busy 2.3 ms per present
NVIDIA GeForce RTX 4090, NVIDIA 615.78.08, Linux 7.3.0-3-cachyos, 1920x1080, commit 9837bacfcdac, dropped: no

{"commit":"9837bacfcdac","dirty":false,"env":{"APS5_DRAW_PIPELINE":"1","APS5_PIPELINED_DRAWS":"32","APS5_PIPELINE_DISPATCH":"1","APS5_TRACE_DIR":"<path>","APS5_TRACE_SECONDS":"60:10"},"gpu":"NVIDIA GeForce RTX 4090","driver":"NVIDIA 615.78.08","os":"Linux 7.3.0-3-cachyos","cpu":"AMD Ryzen 7 7800X3D 8-Core Processor","cpu_threads":16,"memory_mib":31742,"title_id":"PPSA36082","title":"Hades II","content_version":"01.006.000","resolution":"1920x1080","window":{"spec":"seconds 60:10","first_present":5794,"ms":10004.558},"presents":952,"frame_ms":{"p50":10.414,"p90":11.198,"p99":12.259,"max":13.377},"gpu_busy_ms_per_present":2.344,"worker_busy_pct":{"queue worker 0x0":96.595},"top_phases_ms_per_frame":{"Driver.Packet":10.142,"Driver.Packet.draw":7.277,"Graphics.Draw":7.264,"Driver.Draw":7.206,"Driver.DrawFinish":6.438,"Graphics.Draw.draw_and_resource_release":6.036,"Driver.Draw.prepare":4.157,"Driver.DrawFinish.shader_compile_and_link":3.928},"trace_dropped":false,"trace":"aps5-trace-9837bacfcdac-823993.json.gz"}

Slowest frames (largest slices inside each, inclusive)

  • present 6381: 13.4 ms at 6177 ms: Driver.Packet (queue worker 0x0) 5.6, Graphics.Draw (draw committer) 4.7, batch (gpu) 4.3, Driver.Packet.draw (queue worker 0x0) 4.2
  • present 6073: 13.1 ms at 2921 ms: Driver.Packet (queue worker 0x0) 4.0, Driver.Packet.draw (queue worker 0x0) 3.6, Driver.Draw (queue worker 0x0) 3.6, Driver.Draw.prepare (queue worker 0x0) 3.2
  • present 6374: 12.8 ms at 6097 ms: Graphics.Draw (draw committer) 5.0, batch (gpu) 4.6, Graphics.Draw.draw_and_resource_release (draw committer) 4.4, Driver.Packet (queue worker 0x0) 4.1
  • present 6609: 12.8 ms at 8568 ms: Driver.Packet (queue worker 0x0) 4.3, Graphics.Draw (draw committer) 3.3, Driver.Packet.draw (queue worker 0x0) 2.5, Driver.Draw (queue worker 0x0) 2.5
  • present 6129: 12.6 ms at 3514 ms: Driver.Packet (queue worker 0x0) 3.7, batch (gpu) 2.7, Graphics.Draw (draw committer) 2.6, Driver.Packet.draw (queue worker 0x0) 2.4

Threads (ms per frame)

thread busy wait untraced in slices < 20 us largest
queue worker 0x0 2.2 (21 %) 0.0 (0 %) 8.3 27.5 Driver.Packet 2.2, Driver.Completion 0.0
draw committer 2.9 (27 %) 0.1 (1 %) 7.6 10.3 Graphics.Draw 2.9, Recorder.Submit 0.0
title 0.0 (0 %) 0.0 (0 %) 10.5 0.1 Shader.ResolveGraphicsStagesAbi 0.0, Shader.ResolveAbi 0.0
draw finisher 1.5 (14 %) 0.0 (0 %) 9.0 16.6 Driver.DrawFinish 1.5
presenter 0.5 (4 %) 0.0 (0 %) 10.0 0.1 VideoOut.Flip 0.5, Driver.Present 0.0
gpu 2.3 (22 %) 0.0 (0 %) 8.2 0.0 batch 2.3

Largest slices (ms per frame, inclusive, all threads): Graphics.Draw 2.9, batch 2.3, Driver.Packet 2.2, Graphics.Draw.draw_and_resource_release 2.1, Driver.Packet.draw 1.5, Driver.Draw 1.5, Driver.DrawFinish 1.5, Driver.DrawFinish.draw_enqueued 1.0, Driver.Draw.prepare 0.6, Driver.Draw.draw_handed_off 0.6

Longest waits

  • Driver.Present.render_fence_wait (presenter) 1.3 ms at 6063 ms, present 6371
  • GpuMutex.wait.hook (presenter) 0.8 ms at 7538 ms, present 6510
  • Driver.Present.render_fence_wait (presenter) 0.4 ms at 2805 ms, present 6062
  • Driver.Present.gpu_mutex_wait (presenter) 0.4 ms at 2730 ms, present 6055
  • Driver.Present.render_fence_wait (presenter) 0.4 ms at 4671 ms, present 6239
  • Driver.Present.render_fence_wait (presenter) 0.4 ms at 3832 ms, present 6159
  • Driver.Present.render_fence_wait (presenter) 0.4 ms at 2480 ms, present 6031
  • Driver.Present.render_fence_wait (presenter) 0.3 ms at 2989 ms, present 6079
  • Driver.Present.render_fence_wait (presenter) 0.3 ms at 5209 ms, present 6290
  • Driver.Present.render_fence_wait (presenter) 0.3 ms at 5284 ms, present 6297

Largest GPU batches (GPU ranges inside, and the CPU slices that recorded each, inclusive)

  • batch 8213: 1.9 ms at 6066 ms, present 6371: GPU no ranges; recorded by Recorder.Sync (draw committer) 2.2, Graphics.Draw (draw committer) 0.7, Graphics.Draw.draw_and_resource_release (draw committer) 0.2
  • batch 8240: 1.8 ms at 6089 ms, present 6373: GPU no ranges; recorded by Graphics.Draw (draw committer) 0.5, Graphics.Draw.draw_and_resource_release (draw committer) 0.2
  • batch 8226: 1.7 ms at 6077 ms, present 6372: GPU no ranges; recorded by Graphics.Draw (draw committer) 0.3, Graphics.Draw.draw_and_resource_release (draw committer) 0.2
  • batch 8255: 1.4 ms at 6101 ms, present 6374: GPU no ranges; recorded by Graphics.Draw (draw committer) 0.5, Graphics.Draw.draw_and_resource_release (draw committer) 0.3
  • batch 8432: 1.2 ms at 6239 ms, present 6386: GPU no ranges; recorded by Graphics.Draw (draw committer) 0.2, Graphics.Draw.draw_and_resource_release (draw committer) 0.2
this PR 95e1f33 + boykopovar#9533, `APS5_DRAW_PIPELINE=1 APS5_GPU_HEAP=1`

seconds 60:10 from present 6131: 1032 presents, frame p50 9.6 / p90 10.7 / p99 11.9 / max 13.2 ms, GPU busy 2.3 ms per present
NVIDIA GeForce RTX 4090, NVIDIA 615.78.08, Linux 7.3.0-3-cachyos, 1920x1080, commit 37724aa7680e, dropped: no

{"commit":"37724aa7680e","dirty":false,"env":{"APS5_DRAW_PIPELINE":"1","APS5_GPU_HEAP":"1","APS5_PIPELINED_DRAWS":"32","APS5_PIPELINE_DISPATCH":"1","APS5_TRACE_DIR":"<path>","APS5_TRACE_SECONDS":"60:10"},"gpu":"NVIDIA GeForce RTX 4090","driver":"NVIDIA 615.78.08","os":"Linux 7.3.0-3-cachyos","cpu":"AMD Ryzen 7 7800X3D 8-Core Processor","cpu_threads":16,"memory_mib":31742,"title_id":"PPSA36082","title":"Hades II","content_version":"01.006.000","resolution":"1920x1080","window":{"spec":"seconds 60:10","first_present":6131,"ms":10008.044},"presents":1032,"frame_ms":{"p50":9.552,"p90":10.734,"p99":11.937,"max":13.199},"gpu_busy_ms_per_present":2.285,"worker_busy_pct":{"queue worker 0x0":96.278},"top_phases_ms_per_frame":{"Driver.Packet":9.327,"Driver.Packet.draw":6.576,"Driver.Draw":6.507,"Driver.DrawFinish":6.079,"Graphics.Draw":6.022,"Graphics.Draw.draw_and_resource_release":4.888,"Driver.DrawFinish.shader_compile_and_link":4.021,"Driver.Draw.prepare":3.902},"trace_dropped":false,"trace":"aps5-trace-37724aa7680e-824541.json.gz"}

Slowest frames (largest slices inside each, inclusive)

  • present 6212: 13.2 ms at 816 ms: batch (gpu) 5.6, Driver.Packet (queue worker 0x0) 5.1, Driver.Packet.draw (queue worker 0x0) 4.6, Driver.Draw (queue worker 0x0) 4.6
  • present 6206: 12.8 ms at 748 ms: Driver.Packet (queue worker 0x0) 4.4, batch (gpu) 4.4, Driver.Packet.draw (queue worker 0x0) 3.3, Driver.Draw (queue worker 0x0) 3.3
  • present 7064: 12.6 ms at 9063 ms: Driver.Packet (queue worker 0x0) 3.3, Driver.Packet.draw (queue worker 0x0) 3.0, Driver.Draw (queue worker 0x0) 3.0, Driver.Draw.prepare (queue worker 0x0) 2.5
  • present 6221: 12.5 ms at 906 ms: Driver.Packet (queue worker 0x0) 3.7, Driver.Packet.draw (queue worker 0x0) 3.5, Driver.Draw (queue worker 0x0) 3.5, Driver.DrawFinish (draw finisher) 3.3
  • present 6200: 12.5 ms at 680 ms: batch (gpu) 4.7, Driver.Packet (queue worker 0x0) 4.4, Driver.Packet.draw (queue worker 0x0) 3.6, Driver.Draw (queue worker 0x0) 3.6

Threads (ms per frame)

thread busy wait untraced in slices < 20 us largest
queue worker 0x0 1.8 (18 %) 0.0 (0 %) 7.9 25.7 Driver.Packet 1.8, Driver.Completion 0.0
draw committer 1.1 (12 %) 0.1 (1 %) 8.5 10.1 Graphics.Draw 1.1, Recorder.Reap 0.0
title 0.0 (0 %) 0.0 (0 %) 9.7 0.1 Shader.ResolveGraphicsStagesAbi 0.0, Shader.ResolveAbi 0.0
draw finisher 1.1 (11 %) 0.0 (0 %) 8.6 16.0 Driver.DrawFinish 1.1
presenter 0.4 (4 %) 0.0 (0 %) 9.3 0.1 VideoOut.Flip 0.4, Driver.Present 0.0
gpu 2.3 (24 %) 0.0 (0 %) 7.4 0.0 batch 2.3

Largest slices (ms per frame, inclusive, all threads): batch 2.3, Driver.Packet 1.8, Driver.Packet.draw 1.3, Driver.Draw 1.2, Graphics.Draw 1.1, Driver.DrawFinish 1.1, Graphics.Draw.draw_and_resource_release 0.9, Driver.Draw.prepare 0.7, Driver.DrawFinish.draw_enqueued 0.6, Recorder.Sync 0.5

Longest waits

  • Driver.Present.gpu_mutex_wait (presenter) 0.6 ms at 3023 ms, present 6443
  • Driver.Present.render_fence_wait (presenter) 0.5 ms at 704 ms, present 6202
  • Driver.Present.render_fence_wait (presenter) 0.5 ms at 9037 ms, present 7061
  • Driver.Present.render_fence_wait (presenter) 0.4 ms at 8920 ms, present 7049
  • Driver.Present.gpu_mutex_wait (presenter) 0.4 ms at 2010 ms, present 6337
  • Driver.Present.render_fence_wait (presenter) 0.4 ms at 9371 ms, present 7096
  • Driver.Present.render_fence_wait (presenter) 0.4 ms at 5799 ms, present 6728
  • Driver.Present.render_fence_wait (presenter) 0.4 ms at 9104 ms, present 7068
  • Driver.Present.render_fence_wait (presenter) 0.4 ms at 5557 ms, present 6703
  • Driver.Present.render_fence_wait (presenter) 0.4 ms at 5666 ms, present 6714

Largest GPU batches (GPU ranges inside, and the CPU slices that recorded each, inclusive)

  • batch 1156: 1.9 ms at 797 ms, present 6210: GPU no ranges; recorded by Graphics.Draw (draw committer) 0.1, Graphics.Draw.draw_and_resource_release (draw committer) 0.1
  • batch 1187: 1.9 ms at 821 ms, present 6212: GPU no ranges; recorded by Recorder.Sync (draw committer) 3.2, Graphics.Draw (draw committer) 0.1, Graphics.Draw.draw_and_resource_release (draw committer) 0.0
  • batch 1068: 1.4 ms at 728 ms, present 6204: GPU no ranges; recorded by Graphics.Draw (draw committer) 0.1, Graphics.Draw.draw_and_resource_release (draw committer) 0.1
  • batch 1024: 1.4 ms at 696 ms, present 6201: GPU no ranges; recorded by Graphics.Draw (draw committer) 0.1, Graphics.Draw.draw_and_resource_release (draw committer) 0.1
  • batch 1112: 1.4 ms at 764 ms, present 6207: GPU no ranges; recorded by Graphics.Draw (draw committer) 0.1, Graphics.Draw.draw_and_resource_release (draw committer) 0.1
`main` 0835ec8 + boykopovar#9533 (no draw pipeline)

seconds 60:10 from present 5563: 902 presents, frame p50 11.0 / p90 11.8 / p99 12.9 / max 15.2 ms, GPU busy 2.4 ms per present
NVIDIA GeForce RTX 4090, NVIDIA 615.78.08, Linux 7.3.0-3-cachyos, 1920x1080, commit 9837bacfcdac, dropped: no

{"commit":"9837bacfcdac","dirty":false,"env":{"APS5_PIPELINED_DRAWS":"32","APS5_PIPELINE_DISPATCH":"1","APS5_TRACE_DIR":"<path>","APS5_TRACE_SECONDS":"60:10"},"gpu":"NVIDIA GeForce RTX 4090","driver":"NVIDIA 615.78.08","os":"Linux 7.3.0-3-cachyos","cpu":"AMD Ryzen 7 7800X3D 8-Core Processor","cpu_threads":16,"memory_mib":31742,"title_id":"PPSA36082","title":"Hades II","content_version":"01.006.000","resolution":"1920x1080","window":{"spec":"seconds 60:10","first_present":5563,"ms":10006.024},"presents":902,"frame_ms":{"p50":11.019,"p90":11.793,"p99":12.945,"max":15.162},"gpu_busy_ms_per_present":2.436,"worker_busy_pct":{"queue worker 0x0":97.47},"top_phases_ms_per_frame":{"Driver.Packet":10.801,"Driver.Packet.draw":9.072,"Driver.Draw":8.983,"Graphics.Draw":7.347,"Graphics.Draw.draw_and_resource_release":6.089,"Driver.Draw.shader_compile_and_link":5.295,"Shader.DrawStage":3.481,"Shader.DrawStage.capture_resources":1.745},"trace_dropped":false,"trace":"aps5-trace-9837bacfcdac-821781.json.gz"}

Slowest frames (largest slices inside each, inclusive)

  • present 6117: 15.2 ms at 6127 ms: Driver.Packet (queue worker 0x0) 5.0, Driver.Packet.draw (queue worker 0x0) 4.8, Driver.Draw (queue worker 0x0) 4.7, Graphics.Draw (draw committer) 3.9
  • present 6236: 14.4 ms at 7464 ms: Driver.Packet (queue worker 0x0) 6.1, Driver.Packet.draw (queue worker 0x0) 5.9, Driver.Draw (queue worker 0x0) 5.9, Graphics.Draw (draw committer) 4.2
  • present 6116: 14.3 ms at 6113 ms: Driver.Packet (queue worker 0x0) 5.5, Driver.Packet.draw (queue worker 0x0) 4.8, Driver.Draw (queue worker 0x0) 4.8, Graphics.Draw (draw committer) 3.7
  • present 5858: 14.0 ms at 3265 ms: Driver.Packet (queue worker 0x0) 5.6, Driver.Packet.draw (queue worker 0x0) 5.1, Driver.Draw (queue worker 0x0) 5.1, Graphics.Draw (draw committer) 3.4
  • present 6363: 13.3 ms at 8866 ms: Driver.Packet (queue worker 0x0) 4.5, Driver.Packet.draw (queue worker 0x0) 4.3, Driver.Draw (queue worker 0x0) 4.3, Graphics.Draw (draw committer) 2.9

Threads (ms per frame)

thread busy wait untraced in slices < 20 us largest
queue worker 0x0 2.8 (25 %) 0.0 (0 %) 8.3 35.8 Driver.Packet 2.8, Driver.Completion 0.0
draw committer 2.8 (25 %) 0.1 (1 %) 8.2 10.6 Graphics.Draw 2.8, Recorder.Submit 0.0
title 0.0 (0 %) 0.0 (0 %) 11.1 0.1 Shader.ResolveGraphicsStagesAbi 0.0, Shader.ResolveAbi 0.0
presenter 0.4 (4 %) 0.0 (0 %) 10.7 0.1 VideoOut.Flip 0.4, Driver.Present 0.0
gpu 2.4 (22 %) 0.0 (0 %) 8.7 0.0 batch 2.4

Largest slices (ms per frame, inclusive, all threads): Graphics.Draw 2.8, Driver.Packet 2.8, Driver.Packet.draw 2.7, Driver.Draw 2.6, batch 2.4, Graphics.Draw.draw_and_resource_release 2.0, Driver.Draw.shader_compile_and_link 0.5, Driver.Draw.draw_enqueued 0.5, VideoOut.Flip 0.4, VideoOut.Flip.present 0.4

Longest waits

  • Driver.Present.render_fence_wait (presenter) 0.6 ms at 8725 ms, present 6350
  • Driver.Present.render_fence_wait (presenter) 0.6 ms at 6249 ms, present 6127
  • GpuMutex.wait.draw (draw committer) 0.5 ms at 3640 ms, present 5892
  • Driver.Present.render_fence_wait (presenter) 0.4 ms at 1236 ms, present 5675
  • Driver.Present.render_fence_wait (presenter) 0.4 ms at 8989 ms, present 6374
  • Driver.Present.render_fence_wait (presenter) 0.3 ms at 8526 ms, present 6332
  • Driver.Present.render_fence_wait (presenter) 0.3 ms at 4992 ms, present 6015
  • Driver.Present.render_fence_wait (presenter) 0.3 ms at 1597 ms, present 5707
  • Driver.Present.render_fence_wait (presenter) 0.3 ms at 859 ms, present 5641
  • Driver.Present.render_fence_wait (presenter) 0.3 ms at 136 ms, present 5575

Largest GPU batches (GPU ranges inside, and the CPU slices that recorded each, inclusive)

  • batch 4828: 0.9 ms at 3590 ms, present 5887: GPU no ranges; recorded by Graphics.Draw (draw committer) 0.8, Graphics.Draw.draw_and_resource_release (draw committer) 0.2
  • batch 12479: 0.9 ms at 9274 ms, present 6399: GPU no ranges; recorded by Graphics.Draw (draw committer) 0.8, Graphics.Draw.draw_and_resource_release (draw committer) 0.3
  • batch 929: 0.8 ms at 688 ms, present 5625: GPU no ranges; recorded by Graphics.Draw (draw committer) 0.9, Graphics.Draw.draw_and_resource_release (draw committer) 0.3
  • batch 3291: 0.8 ms at 2457 ms, present 5784: GPU no ranges; recorded by Graphics.Draw (draw committer) 0.8, Graphics.Draw.draw_and_resource_release (draw committer) 0.3
  • batch 1581: 0.7 ms at 1172 ms, present 5669: GPU no ranges; recorded by Graphics.Draw (draw committer) 0.8, Graphics.Draw.draw_and_resource_release (draw committer) 0.3
Previous capture (superseded): main 1189ec3 + boykopovar#9533 against this PR d8c243b + boykopovar#9533, 2026-10-30
presents / 10 s frame p50 p90 p99 GPU busy per present queue worker busy
main 1189ec3 + boykopovar#9533 896 11.10 ms 11.88 ms 12.96 ms 2.38 ms 97%
this PR d8c243b + boykopovar#9533, APS5_DRAW_PIPELINE=1 929 10.68 ms 11.47 ms 13.07 ms 2.38 ms 97%
this PR d8c243b + boykopovar#9533, APS5_DRAW_PIPELINE=1 APS5_GPU_HEAP=1 1015 9.72 ms 10.75 ms 12.30 ms 2.25 ms 96%

Traces: https://github.com/Raghav314/AnyPS5/releases/tag/perf-traces-9508-hades-hub

Earlier comparison (superseded): main a6dcea9 + boykopovar#6300 against this PR 23b2a3f + boykopovar#6300

That comparison is kept for the record. Its main trace (de49f41349a9) reported dropped: yes: the trace dropped events, so its digest undercounts slices for that capture, while its summary line's frame times are complete. The two PR traces reported dropped: no. None of the three captures above dropped events.

Title and scene: PPSA36082 (Hades II), the hub (Crossroads), player standing still, APS5_TRACE_SECONDS=120:10. Caches warm: each setting was run once into the hub and the title restarted before its capture. No other APS5_TRACE_* or APS5_PROFILE_* switch, log not redirected (the title ran in a terminal). All three with APS5_PIPELINED_DRAWS=32 APS5_PIPELINE_DISPATCH=1 and nothing else changed.

Current main stops Hades II while the hub loads (native multisample depth metadata fill transition is not implemented), so every build here has boykopovar#6300 merged locally. The main build is a6dcea9 + boykopovar#6300 (local merge commit de49f41349); this PR's is 23b2a3f + boykopovar#6300 (local merge commit 568369d27a), the PR as of the descriptor heap rebind fix on main a6dcea9. Since then the PR's commits changed only by test-only commits and rebases onto newer main; the numbers were not captured again on the current head.

presents / 10 s frame p50 p99 GPU busy per present queue worker busy
main a6dcea9 + boykopovar#6300 706 14.0 ms 18.7 ms 2.22 ms 98%
this PR + boykopovar#6300, APS5_DRAW_PIPELINE=1 886 11.2 ms 13.7 ms 2.34 ms 96%
this PR + boykopovar#6300, APS5_DRAW_PIPELINE=1 APS5_GPU_HEAP=1 1014 9.7 ms 12.1 ms 2.08 ms 96%

The heap is +14% over the draw pipeline alone and +44% over main.

Summary lines

main a6dcea9 + boykopovar#6300

{"commit":"de49f41349a9","dirty":false,"env":{"APS5_PIPELINED_DRAWS":"32","APS5_PIPELINE_DISPATCH":"1","APS5_TRACE_DIR":"<path>","APS5_TRACE_SECONDS":"120:10"},"gpu":"NVIDIA GeForce RTX 4090","driver":"NVIDIA 615.78.08","os":"Linux 7.2.10-1-cachyos","cpu":"AMD Ryzen 7 7800X3D 8-Core Processor","cpu_threads":16,"memory_mib":31743,"title_id":"PPSA36082","title":"Hades II","content_version":"01.006.000","resolution":"1920x1080","window":{"spec":"seconds 120:10","first_present":8859,"ms":10001.243},"presents":706,"frame_ms":{"p50":13.955,"p90":15.665,"p99":18.680,"max":25.064},"gpu_busy_ms_per_present":2.224,"worker_busy_pct":{"queue worker 0x0":97.766},"top_phases_ms_per_frame":{"Driver.Packet":13.844,"Driver.Packet.draw":11.959,"Driver.Draw":11.850,"Driver.Draw.shader_compile_and_link":8.284,"Graphics.Draw":8.166,"Graphics.Draw.draw_and_resource_release":6.859,"Shader.DrawStage":5.206,"Shader.DrawStage.capture_resources":3.196},"trace_dropped":true,"trace_dropped_threads":{"queue worker 0x0":{"events_full_after_s":6.816,"events_lost":132221,"totals_full":false}},"trace":"aps5-trace-de49f41349a9-624652.json.gz"}

this PR + boykopovar#6300, APS5_DRAW_PIPELINE=1

{"commit":"568369d27a2e","dirty":false,"env":{"APS5_DRAW_PIPELINE":"1","APS5_PIPELINED_DRAWS":"32","APS5_PIPELINE_DISPATCH":"1","APS5_TRACE_DIR":"<path>","APS5_TRACE_SECONDS":"120:10"},"gpu":"NVIDIA GeForce RTX 4090","driver":"NVIDIA 615.78.08","os":"Linux 7.2.10-1-cachyos","cpu":"AMD Ryzen 7 7800X3D 8-Core Processor","cpu_threads":16,"memory_mib":31743,"title_id":"PPSA36082","title":"Hades II","content_version":"01.006.000","resolution":"1920x1080","window":{"spec":"seconds 120:10","first_present":10851,"ms":10010.638},"presents":886,"frame_ms":{"p50":11.172,"p90":12.083,"p99":13.652,"max":41.180},"gpu_busy_ms_per_present":2.340,"worker_busy_pct":{"queue worker 0x0":96.015},"top_phases_ms_per_frame":{"Driver.Packet":10.838,"Driver.Packet.draw":8.115,"Graphics.Draw":8.087,"Driver.Draw":8.030,"Driver.DrawFinish":7.151,"Graphics.Draw.draw_and_resource_release":6.678,"Driver.Draw.prepare":4.793,"Driver.DrawFinish.shader_compile_and_link":4.199},"trace_dropped":false,"trace":"aps5-trace-568369d27a2e-626697.json.gz"}

this PR + boykopovar#6300, APS5_DRAW_PIPELINE=1 APS5_GPU_HEAP=1

{"commit":"568369d27a2e","dirty":false,"env":{"APS5_DRAW_PIPELINE":"1","APS5_GPU_HEAP":"1","APS5_PIPELINED_DRAWS":"32","APS5_PIPELINE_DISPATCH":"1","APS5_TRACE_DIR":"<path>","APS5_TRACE_SECONDS":"120:10"},"gpu":"NVIDIA GeForce RTX 4090","driver":"NVIDIA 615.78.08","os":"Linux 7.2.10-1-cachyos","cpu":"AMD Ryzen 7 7800X3D 8-Core Processor","cpu_threads":16,"memory_mib":31743,"title_id":"PPSA36082","title":"Hades II","content_version":"01.006.000","resolution":"1920x1080","window":{"spec":"seconds 120:10","first_present":12138,"ms":10004.892},"presents":1014,"frame_ms":{"p50":9.743,"p90":10.718,"p99":12.061,"max":17.616},"gpu_busy_ms_per_present":2.080,"worker_busy_pct":{"queue worker 0x0":95.834},"top_phases_ms_per_frame":{"Driver.Packet":9.445,"Driver.Packet.draw":6.921,"Driver.Draw":6.847,"Graphics.Draw":6.376,"Driver.DrawFinish":6.362,"Graphics.Draw.draw_and_resource_release":5.216,"Driver.Draw.prepare":3.983,"Driver.DrawFinish.shader_compile_and_link":3.903},"trace_dropped":false,"trace":"aps5-trace-568369d27a2e-625697.json.gz"}

Traces:

Digests (python3 tools/trace_digest.py <trace>)

`main` a6dcea9 + boykopovar#6300

seconds 120:10 from present 8859: 706 presents, frame p50 14.0 / p90 15.7 / p99 18.7 / max 25.1 ms, GPU busy 2.2 ms per present
NVIDIA GeForce RTX 4090, NVIDIA 615.78.08, Linux 7.2.10-1-cachyos, 1920x1080, commit de49f41349a9, dropped: yes

{"commit":"de49f41349a9","dirty":false,"env":{"APS5_PIPELINED_DRAWS":"32","APS5_PIPELINE_DISPATCH":"1","APS5_TRACE_DIR":"<path>","APS5_TRACE_SECONDS":"120:10"},"gpu":"NVIDIA GeForce RTX 4090","driver":"NVIDIA 615.78.08","os":"Linux 7.2.10-1-cachyos","cpu":"AMD Ryzen 7 7800X3D 8-Core Processor","cpu_threads":16,"memory_mib":31743,"title_id":"PPSA36082","title":"Hades II","content_version":"01.006.000","resolution":"1920x1080","window":{"spec":"seconds 120:10","first_present":8859,"ms":10001.243},"presents":706,"frame_ms":{"p50":13.955,"p90":15.665,"p99":18.68,"max":25.064},"gpu_busy_ms_per_present":2.224,"worker_busy_pct":{"queue worker 0x0":97.766},"top_phases_ms_per_frame":{"Driver.Packet":13.844,"Driver.Packet.draw":11.959,"Driver.Draw":11.85,"Driver.Draw.shader_compile_and_link":8.284,"Graphics.Draw":8.166,"Graphics.Draw.draw_and_resource_release":6.859,"Shader.DrawStage":5.206,"Shader.DrawStage.capture_resources":3.196},"trace_dropped":true,"trace_dropped_threads":{"queue worker 0x0":{"events_full_after_s":6.816,"events_lost":132221,"totals_full":false}},"trace":"aps5-trace-de49f41349a9-624652.json.gz"}

Slowest frames (largest slices inside each, inclusive)

  • present 9448: 25.1 ms at 8235 ms: Graphics.Draw (draw committer) 8.2, Graphics.Draw.draw_and_resource_release (draw committer) 6.7, batch (gpu) 2.4, Recorder.Sync (draw committer) 0.5
  • present 9447: 21.4 ms at 8214 ms: Graphics.Draw (draw committer) 6.8, Graphics.Draw.draw_and_resource_release (draw committer) 5.3, batch (gpu) 2.2, Recorder.Sync (draw committer) 0.4
  • present 8967: 20.6 ms at 1554 ms: Driver.Packet (queue worker 0x0) 12.8, Driver.Packet.draw (queue worker 0x0) 12.6, Driver.Draw (queue worker 0x0) 12.5, Driver.Draw.shader_compile_and_link (queue worker 0x0) 5.6
  • present 9476: 20.0 ms at 8689 ms: Graphics.Draw (draw committer) 5.0, Graphics.Draw.draw_and_resource_release (draw committer) 3.9, batch (gpu) 2.1, Recorder.Sync (draw committer) 0.4
  • present 9436: 19.6 ms at 8054 ms: Graphics.Draw (draw committer) 5.2, Graphics.Draw.draw_and_resource_release (draw committer) 3.5, batch (gpu) 2.1, Graphics.Draw.validate (draw committer) 0.8

Threads (ms per frame)

thread busy wait untraced in slices < 20 us largest
queue worker 0x0 3.6 (26 %) 0.0 (0 %) 10.5 28.8 Driver.Packet 3.6, Driver.Draw.shader_compile_and_link 0.0
draw committer 2.6 (18 %) 0.2 (1 %) 11.4 12.8 Graphics.Draw 2.5, Recorder.Reap 0.0
title 0.0 (0 %) 0.0 (0 %) 14.2 0.1 Shader.ResolveGraphicsStagesAbi 0.0, Shader.ResolveAbi 0.0
presenter 0.3 (2 %) 0.0 (0 %) 13.9 0.1 VideoOut.Flip 0.3, Driver.Present 0.0
gpu 2.2 (16 %) 0.0 (0 %) 11.9 0.0 batch 2.2

Largest slices (ms per frame, inclusive, all threads): Driver.Packet 3.6, Driver.Packet.draw 3.5, Driver.Draw 3.4, Graphics.Draw 2.5, batch 2.2, Graphics.Draw.draw_and_resource_release 1.6, Driver.Draw.shader_compile_and_link 1.4, Recorder.Sync 0.3, VideoOut.Flip 0.3, VideoOut.Flip.present 0.3

Longest waits

  • GpuMutex.wait.fill (draw committer) 0.6 ms at 8989 ms, present 9495
  • GpuMutex.wait.draw (draw committer) 0.6 ms at 5107 ms, present 9226
  • GpuMutex.wait.draw (draw committer) 0.6 ms at 9740 ms, present 9547
  • GpuMutex.wait.draw (draw committer) 0.5 ms at 7700 ms, present 9411
  • GpuMutex.wait.fill (draw committer) 0.5 ms at 2460 ms, present 9032
  • GpuMutex.wait.draw (draw committer) 0.5 ms at 1154 ms, present 8940
  • GpuMutex.wait.draw (draw committer) 0.5 ms at 9985 ms, present 9564
  • GpuMutex.wait.draw (draw committer) 0.5 ms at 8917 ms, present 9490
  • Driver.Present.render_fence_wait (presenter) 0.5 ms at 1099 ms, present 8936
  • GpuMutex.wait.draw (draw committer) 0.5 ms at 5976 ms, present 9289

Largest GPU batches (GPU ranges inside, and the CPU slices that recorded each, inclusive)

  • batch 2230: 0.6 ms at 2082 ms, present 9004: GPU no ranges; recorded by Graphics.Draw (draw committer) 0.7, Graphics.Draw.draw_and_resource_release (draw committer) 0.2
  • batch 8347: 0.5 ms at 7633 ms, present 9406: GPU no ranges; recorded by Graphics.Draw (draw committer) 0.7, Graphics.Draw.draw_and_resource_release (draw committer) 0.3
  • batch 7720: 0.5 ms at 7050 ms, present 9366: GPU no ranges; recorded by Graphics.Draw (draw committer) 0.6, Graphics.Draw.draw_and_resource_release (draw committer) 0.1
  • batch 1246: 0.5 ms at 1159 ms, present 8940: GPU no ranges; recorded by Graphics.Draw (draw committer) 0.6, Graphics.Draw.draw_and_resource_release (draw committer) 0.2, Recorder.Reap (draw committer) 0.0
  • batch 9168: 0.5 ms at 8421 ms, present 9459: GPU no ranges; recorded by Graphics.Draw (draw committer) 0.6, Graphics.Draw.draw_and_resource_release (draw committer) 0.3
this PR + boykopovar#6300, `APS5_DRAW_PIPELINE=1`

seconds 120:10 from present 10851: 886 presents, frame p50 11.2 / p90 12.1 / p99 13.7 / max 41.2 ms, GPU busy 2.3 ms per present
NVIDIA GeForce RTX 4090, NVIDIA 615.78.08, Linux 7.2.10-1-cachyos, 1920x1080, commit 568369d27a2e, dropped: no

{"commit":"568369d27a2e","dirty":false,"env":{"APS5_DRAW_PIPELINE":"1","APS5_PIPELINED_DRAWS":"32","APS5_PIPELINE_DISPATCH":"1","APS5_TRACE_DIR":"<path>","APS5_TRACE_SECONDS":"120:10"},"gpu":"NVIDIA GeForce RTX 4090","driver":"NVIDIA 615.78.08","os":"Linux 7.2.10-1-cachyos","cpu":"AMD Ryzen 7 7800X3D 8-Core Processor","cpu_threads":16,"memory_mib":31743,"title_id":"PPSA36082","title":"Hades II","content_version":"01.006.000","resolution":"1920x1080","window":{"spec":"seconds 120:10","first_present":10851,"ms":10010.638},"presents":886,"frame_ms":{"p50":11.172,"p90":12.083,"p99":13.652,"max":41.18},"gpu_busy_ms_per_present":2.34,"worker_busy_pct":{"queue worker 0x0":96.015},"top_phases_ms_per_frame":{"Driver.Packet":10.838,"Driver.Packet.draw":8.115,"Graphics.Draw":8.087,"Driver.Draw":8.03,"Driver.DrawFinish":7.151,"Graphics.Draw.draw_and_resource_release":6.678,"Driver.Draw.prepare":4.793,"Driver.DrawFinish.shader_compile_and_link":4.199},"trace_dropped":false,"trace":"aps5-trace-568369d27a2e-626697.json.gz"}

Slowest frames (largest slices inside each, inclusive)

  • present 11411: 41.2 ms at 6239 ms: Driver.Packet (queue worker 0x0) 32.8, Driver.Packet.draw (queue worker 0x0) 31.6, Driver.Draw (queue worker 0x0) 31.6, Driver.Draw.prepare (queue worker 0x0) 30.1
  • present 11229: 16.1 ms at 4198 ms: Driver.Packet (queue worker 0x0) 5.6, Graphics.Draw (draw committer) 4.7, Driver.DrawFinish (draw finisher) 4.6, Driver.Packet.draw (queue worker 0x0) 4.4
  • present 11231: 15.2 ms at 4228 ms: Driver.Packet (queue worker 0x0) 5.0, Graphics.Draw (draw committer) 3.4, Driver.Packet.draw (queue worker 0x0) 3.0, Driver.Draw (queue worker 0x0) 2.9
  • present 11479: 13.8 ms at 7077 ms: Driver.Packet (queue worker 0x0) 4.4, Graphics.Draw (draw committer) 3.8, Driver.Packet.draw (queue worker 0x0) 3.6, Driver.Draw (queue worker 0x0) 3.5
  • present 11407: 13.8 ms at 6190 ms: Driver.Packet (queue worker 0x0) 4.8, Graphics.Draw (draw committer) 3.6, Graphics.Draw.draw_and_resource_release (draw committer) 3.0, Driver.Packet.draw (queue worker 0x0) 3.0

Threads (ms per frame)

thread busy wait untraced in slices < 20 us largest
queue worker 0x0 2.4 (21 %) 0.0 (0 %) 8.9 29.5 Driver.Packet 2.4, Driver.Completion 0.0
draw committer 2.6 (23 %) 0.2 (2 %) 8.4 12.5 Graphics.Draw 2.6, Recorder.Reap 0.0
title 0.0 (0 %) 0.0 (0 %) 11.3 0.1 Shader.ResolveGraphicsStagesAbi 0.0, Shader.ResolveAbi 0.0
draw finisher 1.7 (15 %) 0.0 (0 %) 9.6 17.8 Driver.DrawFinish 1.7
presenter 0.3 (3 %) 0.0 (0 %) 11.0 0.1 VideoOut.Flip 0.3, Driver.Present 0.0
gpu 2.3 (21 %) 0.0 (0 %) 9.0 0.0 batch 2.3

Largest slices (ms per frame, inclusive, all threads): Graphics.Draw 2.6, Driver.Packet 2.4, batch 2.3, Driver.Packet.draw 1.9, Driver.Draw 1.8, Graphics.Draw.draw_and_resource_release 1.8, Driver.DrawFinish 1.7, Driver.DrawFinish.draw_enqueued 1.0, Driver.Draw.prepare 0.9, Driver.Draw.draw_handed_off 0.5

Longest waits

  • Driver.Present.gpu_mutex_wait (presenter) 1.3 ms at 7138 ms, present 11484
  • GpuMutex.wait.draw (draw committer) 0.8 ms at 6553 ms, present 11434
  • GpuMutex.wait.fill (draw committer) 0.8 ms at 4401 ms, present 11246
  • Driver.Present.gpu_mutex_wait (presenter) 0.7 ms at 690 ms, present 10913
  • GpuMutex.wait.fill (draw committer) 0.6 ms at 1700 ms, present 11004
  • GpuMutex.wait.draw (draw committer) 0.6 ms at 1654 ms, present 11000
  • GpuMutex.wait.draw (draw committer) 0.6 ms at 9033 ms, present 11651
  • GpuMutex.wait.fill (draw committer) 0.6 ms at 4685 ms, present 11272
  • GpuMutex.wait.draw (draw committer) 0.6 ms at 1710 ms, present 11005
  • GpuMutex.wait.draw (draw committer) 0.5 ms at 6239 ms, present 11411

Largest GPU batches (GPU ranges inside, and the CPU slices that recorded each, inclusive)

  • batch 10494: 0.7 ms at 7733 ms, present 11535: GPU no ranges; recorded by Graphics.Draw (draw committer) 1.0, Recorder.Sync (draw committer) 0.8, Graphics.Draw.draw_and_resource_release (draw committer) 0.4
  • batch 979: 0.7 ms at 716 ms, present 10915: GPU no ranges; recorded by Graphics.Draw (draw committer) 1.0, Graphics.Draw.draw_and_resource_release (draw committer) 0.3
  • batch 11842: 0.6 ms at 8716 ms, present 11622: GPU no ranges; recorded by Graphics.Draw (draw committer) 0.8, Graphics.Draw.draw_and_resource_release (draw committer) 0.4
  • batch 13211: 0.6 ms at 9717 ms, present 11711: GPU no ranges; recorded by Graphics.Draw (draw committer) 0.8, Graphics.Draw.draw_and_resource_release (draw committer) 0.4, Recorder.Submit (draw committer) 0.0
  • batch 6893: 0.6 ms at 5013 ms, present 11301: GPU no ranges; recorded by Graphics.Draw (draw committer) 0.3, Graphics.Draw.draw_and_resource_release (draw committer) 0.2
this PR + boykopovar#6300, `APS5_DRAW_PIPELINE=1 APS5_GPU_HEAP=1`

seconds 120:10 from present 12138: 1014 presents, frame p50 9.7 / p90 10.7 / p99 12.1 / max 17.6 ms, GPU busy 2.1 ms per present
NVIDIA GeForce RTX 4090, NVIDIA 615.78.08, Linux 7.2.10-1-cachyos, 1920x1080, commit 568369d27a2e, dropped: no

{"commit":"568369d27a2e","dirty":false,"env":{"APS5_DRAW_PIPELINE":"1","APS5_GPU_HEAP":"1","APS5_PIPELINED_DRAWS":"32","APS5_PIPELINE_DISPATCH":"1","APS5_TRACE_DIR":"<path>","APS5_TRACE_SECONDS":"120:10"},"gpu":"NVIDIA GeForce RTX 4090","driver":"NVIDIA 615.78.08","os":"Linux 7.2.10-1-cachyos","cpu":"AMD Ryzen 7 7800X3D 8-Core Processor","cpu_threads":16,"memory_mib":31743,"title_id":"PPSA36082","title":"Hades II","content_version":"01.006.000","resolution":"1920x1080","window":{"spec":"seconds 120:10","first_present":12138,"ms":10004.892},"presents":1014,"frame_ms":{"p50":9.743,"p90":10.718,"p99":12.061,"max":17.616},"gpu_busy_ms_per_present":2.08,"worker_busy_pct":{"queue worker 0x0":95.834},"top_phases_ms_per_frame":{"Driver.Packet":9.445,"Driver.Packet.draw":6.921,"Driver.Draw":6.847,"Graphics.Draw":6.376,"Driver.DrawFinish":6.362,"Graphics.Draw.draw_and_resource_release":5.216,"Driver.Draw.prepare":3.983,"Driver.DrawFinish.shader_compile_and_link":3.903},"trace_dropped":false,"trace":"aps5-trace-568369d27a2e-625697.json.gz"}

Slowest frames (largest slices inside each, inclusive)

  • present 12364: 17.6 ms at 2219 ms: Driver.Packet (queue worker 0x0) 7.0, Driver.DrawFinish (draw finisher) 5.9, Driver.Packet.draw (queue worker 0x0) 4.9, Driver.Draw (queue worker 0x0) 4.8
  • present 12365: 14.1 ms at 2236 ms: Driver.Packet (queue worker 0x0) 3.5, Driver.Packet.draw (queue worker 0x0) 3.1, Driver.Draw (queue worker 0x0) 3.1, Graphics.Draw (draw committer) 2.6
  • present 12366: 12.8 ms at 2250 ms: Driver.Packet (queue worker 0x0) 3.6, Driver.Packet.draw (queue worker 0x0) 3.1, Driver.Draw (queue worker 0x0) 3.1, Driver.DrawFinish (draw finisher) 2.9
  • present 12396: 12.7 ms at 2557 ms: Driver.Packet (queue worker 0x0) 3.6, Driver.DrawFinish (draw finisher) 2.9, Driver.Packet.draw (queue worker 0x0) 2.8, Driver.Draw (queue worker 0x0) 2.8
  • present 12390: 12.6 ms at 2491 ms: Driver.Packet (queue worker 0x0) 5.2, Driver.Packet.draw (queue worker 0x0) 3.8, Driver.Draw (queue worker 0x0) 3.8, Driver.DrawFinish (draw finisher) 3.5

Threads (ms per frame)

thread busy wait untraced in slices < 20 us largest
queue worker 0x0 2.0 (21 %) 0.0 (0 %) 7.8 25.5 Driver.Packet 2.0, Driver.EndSubmission 0.0
draw committer 1.2 (12 %) 0.3 (3 %) 8.4 10.6 Graphics.Draw 1.2, Recorder.Submit 0.0
title 0.0 (0 %) 0.0 (0 %) 9.9 0.1 Shader.ResolveGraphicsStagesAbi 0.0, Shader.ResolveAbi 0.0
draw finisher 1.4 (15 %) 0.0 (0 %) 8.4 15.5 Driver.DrawFinish 1.4
presenter 0.3 (3 %) 0.0 (0 %) 9.5 0.1 VideoOut.Flip 0.4, Driver.Present 0.0
gpu 2.1 (21 %) 0.0 (0 %) 7.8 0.0 batch 2.1

Largest slices (ms per frame, inclusive, all threads): batch 2.1, Driver.Packet 2.0, Driver.Packet.draw 1.6, Driver.Draw 1.5, Driver.DrawFinish 1.4, Graphics.Draw 1.2, Graphics.Draw.draw_and_resource_release 1.0, Driver.DrawFinish.draw_enqueued 0.8, Driver.Draw.prepare 0.7, Driver.Draw.draw_handed_off 0.6

Longest waits

  • GpuMutex.wait.draw (draw committer) 0.7 ms at 2963 ms, present 12436
  • Driver.Present.gpu_mutex_wait (presenter) 0.7 ms at 5204 ms, present 12664
  • GpuMutex.wait.draw (draw committer) 0.6 ms at 8697 ms, present 13020
  • GpuMutex.wait.draw (draw committer) 0.5 ms at 767 ms, present 12216
  • GpuMutex.wait.draw (draw committer) 0.5 ms at 2324 ms, present 12373
  • GpuMutex.wait.fill (draw committer) 0.5 ms at 806 ms, present 12220
  • GpuMutex.wait.fill (draw committer) 0.5 ms at 8757 ms, present 13026
  • GpuMutex.wait.fill (draw committer) 0.5 ms at 7518 ms, present 12901
  • GpuMutex.wait.draw (draw committer) 0.5 ms at 8797 ms, present 13030
  • GpuMutex.wait.draw (draw committer) 0.5 ms at 7732 ms, present 12922

Largest GPU batches (GPU ranges inside, and the CPU slices that recorded each, inclusive)

  • batch 5868: 0.6 ms at 3966 ms, present 12538: GPU no ranges; recorded by Recorder.Sync (draw committer) 0.7, Graphics.Draw (draw committer) 0.1, Graphics.Draw.draw_and_resource_release (draw committer) 0.1
  • batch 2770: 0.6 ms at 1858 ms, present 12327: GPU no ranges; recorded by Graphics.Draw (draw committer) 0.1, Graphics.Draw.draw_and_resource_release (draw committer) 0.1
  • batch 2372: 0.6 ms at 1593 ms, present 12300: GPU no ranges; recorded by Graphics.Draw (draw committer) 0.1, Graphics.Draw.draw_and_resource_release (draw committer) 0.1
  • batch 2814: 0.6 ms at 1886 ms, present 12330: GPU no ranges; recorded by Graphics.Draw (draw committer) 0.1, Graphics.Draw.draw_and_resource_release (draw committer) 0.1, Graphics.Draw.validate (draw committer) 0.0
  • batch 8289: 0.6 ms at 5594 ms, present 12704: GPU no ranges; recorded by Graphics.Draw (draw committer) 0.1, Graphics.Draw.draw_and_resource_release (draw committer) 0.1

Where this can take more frame rate

The heap moves descriptor work off the CPU, but CPU-bound titles are still bound by the threads recording draws. Follow-ups that build on the heap:

Contributions

  • milescoviello: the memory recovery that evicts heap-held sampled textures (d600dfa, 9188f74), matching cached draws' stages in one heap mode (96f38b8), the Ghost of Tsushima bisect, and the MGS4 heap runs and debug-build crash reports.
  • EagleBearerYS (Yunus Shaikh): the three address-space reuse fixes with their tests (1817bbe, 270d43a, 758d23c), the byte cap of the heap walk memo (b7ac0d6), and the Windows builds of the heap tests.
  • Dean Galvin: the embedded sampler state in the compute pipeline identity (31d84cf), the ElementFlags sizes in the heap budget helpers (15c9133), the relocated-hit test under entry verification (10d2e59), the ring stage draw key with moved-buffer templates off (f07da0c), uniform constant buffer validation under uniformBufferStandardLayout (3f20fdd), the disk cache format move (d943ee9), and the merges of main into the branch (dfcd235, 18247ff).
  • muhmuhkuh: found that dynamic-resolution variants read the template's image table words in heap stages (fixed in 165df48).
  • B-Howell: spotted that a main merge dropped the float rounding test's wave64 compute target (fixed in 1a7d1b7).
  • Dextroid17: test runs on an RTX 3080 Ti.
  • Astronaut10: the RX 9070 XT measurement that pointed at the CPU slot-write cost.

Tested

Linux 7.3.3-1-cachyos (CachyOS), x86-64, GCC, Ryzen 7 7800X3D / RTX 4090, NVIDIA 620.70.06. The AGC, shader and recompiler tests, each mode with ANYPS5_REQUIRE_VULKAN=1 ANYPS5_NO_SHADER_CACHE=1 APS5_NO_PIPELINE_BINARIES=1 and the validation layer:

ANYPS5_REQUIRE_VULKAN=1 ANYPS5_NO_SHADER_CACHE=1 APS5_NO_PIPELINE_BINARIES=1 VK_INSTANCE_LAYERS=VK_LAYER_KHRONOS_validation ctest --test-dir build -R 'agc_driver|recompiler|shader' -j8 --timeout 600 -V
APS5_GPU_HEAP=1 ANYPS5_REQUIRE_VULKAN=1 ANYPS5_NO_SHADER_CACHE=1 APS5_NO_PIPELINE_BINARIES=1 VK_INSTANCE_LAYERS=VK_LAYER_KHRONOS_validation ctest --test-dir build -R 'agc_driver|recompiler|shader' -j8 --timeout 600 -V
  • c1c98c1 (head): 1422 tests per mode pass in default and heap mode, 0 VUID-.
  • b635a72 (the same branch code before the last two merges of main): 1417 tests per mode pass in default, heap, and heap with APS5_VERIFY_GPU_HEAP=1, 0 VUID-. With the heap and the draw pipeline (APS5_DRAW_PIPELINE=1 APS5_PIPELINED_DRAWS=32 APS5_PIPELINE_DISPATCH=1) all pass except agc_driver_queued_constant_ram_dump and agc_driver_draw_recapture_on_change_inline, which are not written for the draw finisher and fail the same way on earlier heads.
  • The *_gpu_heap tests run the draw pipeline PR's switched tests and the sampling, table, atomics, compute, mesh relocation, thread-dimension dispatch, eviction and dynamic-resolution variant tests with APS5_GPU_HEAP=1 APS5_VERIFY_GPU_HEAP=1. New tests were checked against the code before their fix.
  • Dextroid17 ran dd7120c merged onto main on an RTX 3080 Ti (NVIDIA 615.78.08): 3,121 passed, 49 skipped; the one failure, agc_driver_idle_store_yields, also fails on main.
  • Hades II as above (with fix(agc): import native multisample D32S8 targets with a separate stencil plane and a depth-only HTILE boykopovar/AnyPS5#9533 merged locally). Grand Theft Auto V runs in game on the head's heap code with no heap errors; Minecraft Dungeons II and Hades II took no per-draw fallback before it was removed. Astro's Playroom (PPSA01325) runs into the game with no flicker.

Known limits

  • A stage that needs more image slots than the heap holds, or whose module keeps a binding the heap does not map (registration-module set 0 storage images), fails with an error instead of running per-draw. No title run so far has hit either. The technical debt file lists them.
  • With APS5_HEAP_SLOT_CAP far below the default, stages that each fit can still exhaust the heap between their compile and their bind, because the nearly-full margin scales with the cap.
  • The heap needs the released revision of VK_EXT_descriptor_heap, timeline semaphores, and heaps that hold the shared image slot pool and 2048 samplers. Other devices run the existing path.
  • Ghost of Tsushima (PPSA02225) whited out with the heap on when compute stages wrote storage images through it (milescoviello's bisect). eb60688 and 95e1f33 fixed the two heap paths that made such stores write zeros (multisampled targets, and uint stores through image tables), each with a _gpu_heap test. milescoviello confirmed the white-out is gone, and the full heap runs in-game to his 1,200 s timeout.
  • milescoviello's MGS4 runs with the heap and the draw pipeline hit a glibc heap-corruption abort, once in the walk memo's eviction and once at teardown. The walk memo is deleted (7035a25). It has not reproduced here under glibc.malloc.check=3, ASan or ThreadSanitizer; his rerun on the current head is pending.

Testing other titles

Please post:

  • the title ID, GPU, driver and OS;
  • the summary line (APS5_TRACE_SECONDS=70:10, captured as the Performance report form describes: warm caches, no other trace or profile switch, log not redirected) with APS5_DRAW_PIPELINE=1 and with APS5_GPU_HEAP=1 APS5_DRAW_PIPELINE=1, both with APS5_PIPELINED_DRAWS=32 APS5_PIPELINE_DISPATCH=1 and nothing else changed;
  • whether anything renders differently (wrong or missing textures, flicker);
  • any heap error that stops the title (it names the stage's slot count or unmapped binding);
  • with APS5_VERIFY_GPU_HEAP=1, the last [heap-slots] and [gpu-heap] lines (a slot holding another texture or a differing stage is a bug).

Checklist

  • Based on current main; no other open PR implements the same functions
  • One topic per PR; follow-ups go in a new PR
  • No comments in code except technical debt
  • Unimplemented paths throw (NotImplemented_nid_no_patch); silent stubs are listed under Silent stubs in their library's technical debt file
  • No notes, investigation .md files or images added to the repository (attach them to this PR)
  • New third-party code is a submodule built from source (Vulkan-Headers bumped to 1.4.340)
  • Generic behaviour, not specific to one title
  • Depends on: none (perf(agc): draw finisher pipeline (APS5_DRAW_PIPELINE) boykopovar/AnyPS5#6946 is merged)
  • Unblocks: none
  • GPUs tested: NVIDIA GeForce RTX 4090, 620.70.06, Linux 7.3.3-1-cachyos (CachyOS); RTX 3080 Ti, 615.78.08 (Dextroid17)
  • AI-assisted: yes

Raghav314 and others added 30 commits October 31, 2026 10:52
main omits the final zero select for read-only and volatile buffer loads,
relying on robust buffer access to return zero for the out-of-range
fallback index. Heap stages read guest buffers through device addresses,
whose out-of-range fallback loads word 0 of the buffer, so those loads
returned data (agc_driver_buffer_descriptor_runtime with APS5_GPU_HEAP=1).
Address loads keep the select.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Per-dispatch image tables still bind every storage element through its
float view, so the store test fails without the heap; it now skips there
and the gap is recorded in the driver's debt file.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…on, not the driver's Vulkan version

Drivers ship the released VK_EXT_descriptor_heap (revision 1) while
reporting an older Vulkan version (NVIDIA 595.99.02 reports 1.4.329), and
every heap test passes on them. The heap now needs revision 1 or newer;
the validation layer gate stays.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
# Conflicts:
#	core/libs/prx/libSceAgcDriver/Graphics/src/ShaderResources.cpp
A retired single-sample depth surface stayed alive while any of its
sampled views had another holder. A GPU heap slot is such a holder, and
the heap frees a slot only once the heap is its view's only holder,
which the surface's own view map prevents. With the GPU heap on, every
retired depth surface a title had sampled stayed alive for good.

releaseRetired now ignores holds that heap slots account for. The views
own their image (as multisample ones already did), so a slot keeps
sampling a valid image until the next sweep, which release() requests.
The stencil copy's views own its image the same way.
A heap slot held a shared reference to its texture, storage image or
sampler, and the heap freed slots by sweeping for owners it alone held.
Every way an owner can leave its caches then needed its own rule (images
in several slots, images that left the storage cache, retired depth
surfaces), and the ones missed stayed resident: under memory pressure
evicted storage images waited for the next present, the storage budget
counted them as memory outside the caches, and the cache shrank to its
floor while they stayed alive.

A slot now names its owner by address only, as view slots already did.
Textures, storage images and samplers free their slots when they are
destroyed. That is safe because every batch that reads a slot keeps the
slot's owner alive through its draw's or dispatch's resources, the same
guarantee the per-draw path relies on for its descriptor sets, so a slot
is never reused while a batch can read it. The sweeps, heap holds and the
present-time sweep go; a heap refused for lack of free slots comes back
when released slots leave twice the margin free.

agc_driver_storage_cache_budget_heap_slots runs the storage budget test
with every stored image bound to a heap storage slot; evicted images
must be freed at once and give their slots back.
Remove dead heap API and counters, name magic numbers, share the image slot path, and mix the slot key hash so a view used as its own owner no longer collides.
Texture, StorageTexture, Sampler, MultisampleTarget and presentation slots derive from HeapSlotOwner, which frees all of an owner's slots with one call and only when the heap gave it some. Image and sampler slots share SlotPool, the statistics read each heap's counts instead of a second set of counters, the heap lookup cache no longer depends on the draw pipeline, and multisample storage views are keyed by their target instead of by the view itself.
…le targets

A cached build keeps the BDA page table it was built with, filtered by the multisample-target guard generation of that moment. A new resident multisample target bumps only that generation, so a space-reuse hit kept binding a table that still mapped the target's guest memory. The build now keeps the generation its table was filtered at; a hit whose generation moved reruns ExcludeMultisampleTargetRanges over the build's space ranges and keeps the hit only when the result matches its table.

Ported from boykopovar#13858 (a142526).

Co-authored-by: Yunus Shaikh <75296019+EagleBearerYS@users.noreply.github.com>
Remove dead draw-pipeline write queries and the duplicate GraphicsContext accessor, extract the direct-heap capture without a goto, share the user-data mask, keep one ring template per cached variant, split the draw stage retry into named helpers, bundle materializeDrawStage's per-draw state, name the heap fragment key classes and descriptor-heap constants, and copy a dispatch's push block only when it is patched.

The patched-stage re-materialize now passes the heap-pair refusal like the other two materializeDrawStage calls; it used the defaulted heapPartners = true.
Remove the dead storage-texture cache flag, share one buffer device-address query, read owned buffers' cached addresses, look the device function cache up before the descriptor-heap hooks, count bind and record statistics only when they are reported, classify heap bindings without goto, name the heap shader checks and pipeline-library key tags, share the descriptor-heap pipeline flags, keep encoded image views in their view record, and add APS5_NO_SPACE_REUSE to turn space reuse off on its own.
Drop the second encode/decode of userDataRegisterReads in the disk cache, remove always-true heap conditions, share heap templates by pointer and build their words outside the source lock, name the heap parts, storage-kind stride and slot word sizes, share the root stage table with the driver, and replace positional bool parameters with named option structs.
A draw whose shader data exceeded one 2 MiB ring chunk threw 'per-draw data exceeds a ring chunk' (Death Stranding 2 reaches 2.4 MiB per compute dispatch). A span may now cover several chunks and stays held while none of them has been written over: each chunk records the ring entry at which it was last entered, and a span is held only while every chunk it covers was entered no later than the span itself. Only data larger than half the ring is refused.
…ts cursor

After a wrap, the kept-chunk skip loop treated the current chunk as free, so with every other chunk kept a span could land at the start of the current chunk and write over shader data the open batch had already written, without marking that chunk entered. The current chunk now counts as taken when the new span starts behind the ring cursor; a ring with no room left refuses the span as before.
With APS5_GPU_HEAP=1 the first pixel-function LDS preparation created the GPU heap, adding the heap's own buffers to the counted allocations, and the heap's context copy kept the test's buffer pool alive past its reset. The test now creates the heap before installing its pool and taking its baseline, so it holds in both modes.
HeapWalkMemo's slot, pin, charge, drop, release and trim helpers are private, remember() stamps entries through touch(), and slot() and trim() share one retirePrevious().
agc_shader_replay --gpu-heap sets the target fields the device sets with APS5_GPU_HEAP=1 (GPU-resolved images, descriptor memory and the 16384-dword heap data uniform), so captured requests can be recompiled in heap mode.
One 64-bit address composer, aligned word loads, the image first-element dword, shared descriptor set and binding numbers, one heap array definition that creates its slot-count constant before the element type, derived table-heap and BDA state flags, the read-only storage buffer type and the table map load. Emitted SPIR-V is byte-identical: 945 captured game shaders in plain and GPU heap mode and the image-table test shaders.
GPU heap test variants now skip instead of passing on the per-draw path when the device has no descriptor heap. One env-test registration helper, one heap sample kernel shared by the compute-sample and journal tests, shared environment and no-heap skip helpers, loops instead of repeated draw-sample calls, and removed dead branches, diagnostics, locals and includes. The registered test list and every test's command and environment are unchanged.
…ields in serialized shader requests

Request serialization version 52 writes gpuResolvedImages, descriptorMemory and heapDataUniformDwords, then ldsLockFences, meshWindowBuffer, waveLdsMemoryBarriers, deviceScopeLdsMemoryBarriers, exactRobustLoads and robustBufferAccess2, so a dump keeps every target field that the shader cache key includes and that selects an emitter path. Older versions deserialize to heap off with limit 0 and the other fields off, as before.
…rridden

agc_shader_replay keeps the captured heap profile and prints it with its source. --gpu-heap, --no-gpu-heap and --heap-data-uniform-dwords N are explicit overrides; --gpu-heap with --no-gpu-heap and --no-gpu-heap with a nonzero limit exit 2. The target flag options force their flag on over the captured value and are listed on a forced-on line. The replay tool check compares SPIR-V of requests whose shader reads shader data, so the uniform and addressed limits differ.
APS5_GPU_HEAP turned the heap on whenever it was set, so =0 enabled it,
while USAGE.md documents =1. Read it as a boolean like
APS5_ASYNC_DRAW_COMPILE, and have the heap tests ask GpuHeapEnabled
instead of reading the variable themselves.

APS5_HEAP_SLOT_CAP, APS5_PUSHED_BUFFER_RECORDS,
APS5_EMBEDDED_SAMPLER_CAP, APS5_HEAP_TEMPLATE_MIB and
APS5_VERIFY_GPU_HEAP went through strtoul, so a typo or -1 silently
changed the cap. Parse them with from_chars and stop with an error that
names the variable, as APS5_DUMP_COMPUTE_MIN_WORDS does. HeapDrawBench
skips without a descriptor heap device, as HeapDrawSample does.
…again

The heap branch replaced the SPIR-V scan with the emitter's bdaStores
flag on every path, so the heap-off reuse decisions changed. Heap
programs need the flag, since their fault report is written through an
address and the scan counts that as a store. ProgramStoresThroughAddresses
scans classic programs as before and reads the flag only for heap
programs, at all three sites. Restore main's scan tests, and check that a
classic program storing through an address counts as storing whatever
its flag says, and that a heap program follows its flag.
…self

The buffer's address is queried for the heap CMASK pipeline. It got the
device-address usage only because heap mode forces it on every storage
buffer; ask for it where the heap pipeline exists.
readWalkWord recorded reads at any address, while the range copy sizes
ranges in whole words and copies their bytes, so overlapping misaligned
reads could write past the copy. Reject them as readWalkWords does; the
walk then declines and the stage takes the per-draw capture. Also reset
a stage's registered views and supplied blocks with its other capture
fields, so a heap-direct stage does not keep the previous draw's.
Submitted gave the batch's retirements and pool blocks the next serial
before vkQueueSubmit, so a failed submit left them waiting on a serial
that never completes.
CreateHeapStagePipeline used the pipeline cache without the use lock its
neighbours take. The upscaler held that shared lock across its heap
create, which would now take it twice, so its lock covers only the
classic create.
…raw path

A1: drop a stage's earlier heap-read regions from the draw's memory view before it is recaptured, so the spans never point into heapReadWords that the recapture resets.

A2: the heap walk's pending-write check also runs on the draw finisher thread, where the thread-local pipeline flag is false, so a queued descriptor-table write is no longer missed. A new test enqueues a Queue0 write over the table and runs the walk on the finisher.

A19: heap exclusion preparation for a dispatch runs inside the refused-dispatch handling, so a preparation exception is skipped or reported like the others.

A20: a nonzero APS5_DUMP_DRAW_SHADERS or APS5_DUMP_DRAW_SLOT1 target forces a full capture without APS5_PROFILE_DRAW.
…ap compute capture

A3: the trailing dispatch barrier makes uniform reads visible and the leading barrier is elided only when uniform reads are covered too.

A4: heap compute pipelines are not captured, since a capture keeps neither their descriptor heap mappings nor the heap image slot specialization. A new run test dispatches a heap compute shader with the dump directory set and expects no capture.
A5: the real vkCreateImageView, vkDestroyImageView, vkCreateSampler and vkDestroySampler pointers are kept per VkDevice and each wrapper dispatches through the entry of its own device argument, instead of one process-wide pointer the last resolving device overwrote.

A6: image view and sampler records, and the encoded descriptors kept with a view, are keyed by device and handle, and the lookup, copy and keep calls take the device. A new host-only test drives two fake devices through the hooks.
…atch if the heap hook throws

A10: the missing-timeline check for a heap batch runs before vkQueueSubmit. A failure of the heap submission hook after a successful submit no longer skips the bookkeeping: the batch enters inFlight and the error is rethrown afterwards, so the GPU's resources and completion actions are not lost. noTimelineFails now also expects that nothing was submitted.
…ing footprints

A11: a failure after buildComplete, in the heap table layout or refresh, retires the heap tables and releases the descriptor resources before rethrowing, in both build and Complete.

A13: MovedDispatchBuffers reads the guest buffer words through DrawGuestWords, which are the per-draw words of a heap stage.

A15: heap sampled view selection uses ArrayView() for textures shared as an array partner, after the first-layer choice.

A16: the cached shader data comparison builds its iterator only after the sizes matched.

A17: the storage texture pending-overlap fast path checks all ranges against one registry snapshot and validates its version after the scan.

A18: depth and stencil plane footprints of a multisampled target use the multisample footprint, single-sample targets keep DepthSliceBytes.
…late budget

B1: PipelineSpecialization::PlacePushData no longer rejects a placement that leaves the optional UserData root item without a push position; every other root item still needs one.
B2: PreparedShaderInvocation::Plan returns a shared pointer copied under the source mutex instead of a reference to the member the writers reset, and MaterializeHeap compares the capture's plan through it. No caller holds the source mutex.
B3: a registration-mode dynamic-mip storage image write read the first element's slot for every mip. Registration layouts now carry slot words for the storage image kinds (IrBindingLayout::HeapSlotWordKind), the binding builder fills them per element, and the emitter loads the word of each mip beyond the first.
B4: OwnedBytes counts DescriptorBinding::samplerEmbedded and samplerEmbeddedWords and RecompileResult::pushedData.

Tests: PushDataPlacements (B1), ShaderDiskCache (B2), ShaderMemory (B3) and HeapTemplateBudgetTests (B4) fail without the fix.
B5: samplersEvicted submits once before the pressure check.
B6: BindlessHeapSlots uses constructed Texture objects over real images, not byte storage.
B7: Recorder compares the refreshed keys with DccKeys::Clear0000.
B10, B19: tests that build their own recorder pass VulkanDevice::TimelineSemaphores() instead of true (ColorWriteMaskDynamic, CopyInputLifetime, DepthFastClearSubmit, MultisampledPassOrder, PassBreakReasons).
B12: DrawPipelineStop waits for DrawPipeline::FullWaiters() instead of sleeping.
B13: PushDataPlacements lets a position be shared only by the same root item.
B14: DrawWriteRanges covers storage images whose words come from a heap stage.
B15: FinisherHitLookup requires the draw cache hits to increase across the measured submission.
B16: FinisherDispatchOrder samples the draws' color target, changing its color between passes.
B17: HeapDrawBench drops the declarations it never uses.
B18: HeapWalkThreads waits for a peer stage and releases both workers on failure.
B20: PreparedGraphics picks the regular stage by role and checks the unchanged request first.
B21: ImageTableCacheBounds StoreTable checks heap support before setup and dispatch.

B8, B9 and B11 are not defects: heapViewTests returns the skip code 77 with a message, both --atomic-table and --store-table are implemented, and the fragment ShaderData binding is 1 * 66 + 62 = 128.
B22: ARCHITECTURE.md and the GPU descriptor heap debt entry now agree. Registration of a stage whose module does not map only skips its pipeline-library prebuild; RequireHeapStageMappable, the eligibility check and the mixed-draw check make the draw or dispatch throw.
- VariantValidation.cpp:172: the verify-skip check throws only while the pending
  image serial is still the one the cached proof was taken at, so a concurrent
  publication follows the existing PendingMoved path.
- DrawCapture.cpp:406 (and the change checks at Draw.cpp:1445,1516,1543): a
  stage re-run from the indirect-draw patch loop keeps the read regions of
  every recompiled direct stage except its own, not only of earlier ones.
- ShaderRegistry.cpp:1700 and :2405: a failed optional heap preparation is
  logged and skipped, keeping the ordinary entries; the graphics ABI path
  still throws when it is not deferring.
- RecycledShared.hpp:33: a zero-capacity pool hands out the new object
  without retaining it instead of indexing an empty vector.
- DispatchCache.cpp:71: variant byte accounting includes the retained ring
  template and its vectors, on add and on removal.
- BindlessHeap.cpp:407: a slot taken from the image or sampler pool goes back
  to its pool when encoding its descriptor throws.
- BindlessHeap.cpp:1613: retiring slots remember the recorder whose batch
  assigned their serial and are reclaimed against that recorder's timeline.
- BindlessHeap.cpp:1632: a destroyed recorder is detached from retiring
  slots, pool blocks and retired tables after its Sync(), so completion
  bookkeeping never dereferences it.
- DescriptorHeapObjects.cpp:144: sampler records count creations per device and
  handle and are erased only on the last matching destruction.
- Draw.cpp:2402: the held-space guard is released only after RefreshHeapStage
  succeeds, so a failed refresh no longer leaves guest allocations pinned.
- ShaderResources.cpp:2494: heap presence is decided across all shaders before
  any binding is processed, matching the set-layout producer.
- ShaderResources.cpp:7617: a heap stage refuses (cache miss, rebuild) a moved
  buffer that a conventional binding shares and that is not read in place,
  instead of leaving that descriptor on the old allocation.
- ShaderResources.cpp:8134: heap image table resolution selects the array view
  for entries recorded in arrayViewTextures.
- ShaderValidation.cpp:715: a matched image table declaration is recorded in
  declared, so it is not counted again as an undeclared addressed binding.
ShaderReplay.cpp:114: the --no-gpu-heap precheck remembers the first nonzero
--heap-data-uniform-dwords instead of only the last, so a later zero cannot
hide the conflict of an earlier request.
…ailable

SpirvDescriptors.cpp:289 (D2): the sampler heap emitted
SampledImageArrayDynamicIndexing without checking the device, so a device
lacking it failed later at pipeline creation. It now goes through
RequireDynamicIndexing like the image heaps and reports an emission error
naming the sampler binding.

Test: HeapTableStageReuse compiles a table image with a heap sampler on a
target stripped of the capability and requires the sampler heap error; it
fails without the fix (no error at emission).
…ragment

agc_shader_memory_tests.cmake:67 (D11): the agc_driver_image_table_atomics,
agc_driver_image_table_atomics_gpu_heap and agc_driver_image_table_store_gpu_heap
registrations run agc_driver_image_table_cache_bounds_tests, so they move to
agc_driver_image_table_cache_bounds_tests.cmake with their arguments,
environment and timeout unchanged.
USAGE.md:583 (D17): the GPU descriptor heap section did not say that heap
mode has no per-draw fallback. It now states that an ineligible or unmappable
stage fails the draw or dispatch and that running without APS5_GPU_HEAP is
the workaround.
BindlessHeapSlots.cpp:52 (D3): the texture fixture now allocates memory and
binds it to the image before creating the view, and frees it with the image.
DepthFastClearSubmit.cpp:368 (D4): both recreated recorders take
device.TimelineSemaphores() instead of a hardcoded true.
AddressDrawSpaceReuse.cpp:872 (D7): the pending-fill assertion expects Reused
when HeapStages || inPlace; with APS5_NO_MOVED_BUFFERS_IN_PLACE=1 and
--heap-stages the old expression fails.
DescriptorHeapObjectDevices.cpp:63 (D8): each fake device now has its own
callbacks that abort when called for another device, so a hook cache shared
across devices fails; with the per-device map replaced by one slot the test
aborts.
ImageAtomics.cpp (D9): the contended add and umax cases run on
device.ComputeTarget(waveSize) and check the stage's mode, and one Target()
case keeps the plain path covered.
DrawRecipeMovedBuffer.cpp:2 (D12): the heap variants skip (77) when the device
lacks descriptor heaps; the _gpu_heap_unverified registration has no
APS5_VERIFY_GPU_HEAP, so it could pass through descriptor sets.
FinisherDispatchOrder.cpp:156 (D13): both drains are checked in each pass
before the next pass overwrites them.
HeapEmbeddedSampler.cpp:115 (D14): the embedded sampler count is compared with
the parsed cap, so a nonzero cap passes and zero still requires no embedding.
ScratchPool.cpp:268 (D15): the pipeline check is guarded by
DescriptorHeapEnabled() instead of the requested heap mode.
… relocation test

APS5_VERIFY_DRAW_ENTRIES and APS5_VERIFY_DRAW_DATA_HITS turn a hit into a
verify draw: lookupDraw clears drawHit, the draw builds in full, and
cacheDrawStages inserts it. The second-moved-table check added by boykopovar#19267
required zero inserts and so only held when the hit was served from the
cache. The two verify tests registered by the GPU heap PR run that check
in those modes, where the insert is the verify capture, not a lost hit.
Require exactly one insert in those modes and none otherwise.
…ified as a data hit

With APS5_VERIFY_DRAW_DATA_HITS a relocated stage data hit is verified, not served (DrawLookup.cpp sets drawHit false), so a pipelined run never restarts it on the draw finisher. The finisher-restart requirement from boykopovar#19267 now applies only when data hits are not verified; agc_driver_draw_cache_relocation_data_hits_verify_gpu_heap failed it under APS5_DRAW_PIPELINE=1 APS5_PIPELINED_DRAWS=32.
@github-actions

github-actions Bot commented Dec 2, 2026 •

Copy link
Copy Markdown

Other open pull requests touch the same code. Merging one will break the other, or both implement the same thing. If this one builds on them, list them in Depends on.

Pull request Conflicting files (lines on main) Same exports Same new files
PR 28 core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_gpu_indirect_arguments_misaligned_writer_ahead_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_gpu_indirect_arguments_written_ahead_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_indirect_arguments_written_ahead_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_indirect_patched_stage_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_rect_list_indirect_tests.cmake
PR 74 core/libs/prx/libSceAgcDriver/Execution/include/Driver/Draw/HeapStages.hpp
core/libs/prx/libSceAgcDriver/Execution/src/Driver/Draw/HeapStages.cpp
core/libs/prx/libSceAgcDriver/Graphics/include/BindlessHeap.hpp
core/libs/prx/libSceAgcDriver/Graphics/include/DescriptorHeapObjects.hpp
core/libs/prx/libSceAgcDriver/Graphics/src/BindlessHeap.cpp
core/libs/prx/libSceAgcDriver/Graphics/src/DescriptorHeapObjects.cpp
core/libs/prx/libSceAgcDriver/tests/BindlessHeapSlots.cpp
core/libs/prx/libSceAgcDriver/tests/PushDataPlacements.cpp
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_bindless_images_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_buffer_atomics_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_buffer_format_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_compute_table_calls_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_depth_storage_dispatch_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_dispatch_move_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_draw_data_hit_user_words_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_draw_relocate_user_values_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_fragment_user_data_tail_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_gpu_indirect_arguments_misaligned_writer_ahead_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_gpu_indirect_arguments_written_ahead_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_heap_compute_sample_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_heap_draw_sample_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_heap_slots_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_atomics64_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_atomics_bitwise_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_atomics_float_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_atomics_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_cache_bits_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_gather_one_dimensional_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_load_packed_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_sample_border_color_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_sample_derivatives_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_sample_shared_sampler_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_srgb_load_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_store_array_through_volume_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_store_face_on_cube_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_store_float_rounding_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_store_line_through_plane_array_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_store_line_through_plane_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_store_packed_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_store_sint_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_store_unorm_rounding_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_store_volume_through_array_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_table_cache_bounds_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_texel_status_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_indirect_arguments_written_ahead_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_indirect_patched_stage_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_lds_beyond_device_limit_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_mesh_draw_relocation_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_mesh_index_cache_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_mesh_provoking_vertex_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_pixel_barycentric_emulation_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_push_data_placements_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_push_only_heap_passes_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_recorded_draw_staging_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_rect_list_indirect_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_scratch_pool_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_storage_one_slice_alias_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_tessellation_submit_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_view_past_last_mip_tests.cmake
core/libs/prx/libSceAgcDriver/tests/execution/DeviceFunctionCache.cpp
core/libs/prx/libSceAgcDriver/tests/execution/HeapComputeSample.cpp
core/libs/prx/libSceAgcDriver/tests/execution/HeapDrawSample.cpp
core/libs/prx/libSceAgcDriver/tests/execution/HeapSampleKernel.hpp
core/libs/prx/libSceAgcDriver/tests/execution/HeapTableStageReuse.cpp
core/libs/prx/libSceAgcDriver/tests/execution/PushOnlyHeapPasses.cpp
core/libs/prx/libSceAgcDriver/tests/execution/TessellationSubmit.cpp
core/shader/recompiler/HeapTemplateBudget.hpp
core/shader/recompiler/PushDataLayout.hpp
core/shader/recompiler/tests/HeapTemplateBudgetTests.cpp
PR 131 core/libs/prx/libSceAgcDriver/Execution/include/Driver/Draw/HeapStages.hpp
core/libs/prx/libSceAgcDriver/Execution/src/Driver/Draw/HeapStages.cpp
core/libs/prx/libSceAgcDriver/Graphics/include/BindlessHeap.hpp
core/libs/prx/libSceAgcDriver/Graphics/include/DescriptorHeapObjects.hpp
core/libs/prx/libSceAgcDriver/Graphics/src/BindlessHeap.cpp
core/libs/prx/libSceAgcDriver/Graphics/src/DescriptorHeapObjects.cpp
core/libs/prx/libSceAgcDriver/tests/BindlessHeapSlots.cpp
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_bindless_images_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_buffer_atomics_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_buffer_format_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_compute_table_calls_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_depth_storage_dispatch_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_dispatch_move_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_draw_data_hit_user_words_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_draw_relocate_user_values_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_fragment_user_data_tail_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_gpu_indirect_arguments_misaligned_writer_ahead_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_gpu_indirect_arguments_written_ahead_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_heap_compute_sample_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_heap_draw_sample_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_heap_slots_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_atomics64_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_atomics_bitwise_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_atomics_float_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_atomics_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_cache_bits_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_gather_one_dimensional_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_load_packed_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_sample_border_color_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_sample_derivatives_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_sample_shared_sampler_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_srgb_load_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_store_array_through_volume_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_store_face_on_cube_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_store_float_rounding_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_store_line_through_plane_array_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_store_line_through_plane_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_store_packed_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_store_sint_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_store_unorm_rounding_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_store_volume_through_array_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_table_cache_bounds_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_texel_status_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_indirect_arguments_written_ahead_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_indirect_patched_stage_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_lds_beyond_device_limit_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_mesh_draw_relocation_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_mesh_index_cache_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_mesh_provoking_vertex_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_pixel_barycentric_emulation_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_rect_list_indirect_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_storage_one_slice_alias_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_tessellation_submit_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_view_past_last_mip_tests.cmake
core/libs/prx/libSceAgcDriver/tests/execution/DeviceFunctionCache.cpp
core/libs/prx/libSceAgcDriver/tests/execution/HeapComputeSample.cpp
core/libs/prx/libSceAgcDriver/tests/execution/HeapDrawSample.cpp
core/libs/prx/libSceAgcDriver/tests/execution/HeapSampleKernel.hpp
core/libs/prx/libSceAgcDriver/tests/execution/HeapTableStageReuse.cpp
core/libs/prx/libSceAgcDriver/tests/execution/TessellationSubmit.cpp
core/shader/recompiler/HeapTemplateBudget.hpp
core/shader/recompiler/tests/HeapTemplateBudgetTests.cpp
PR 151 core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_cache_bits_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_texel_status_tests.cmake
PR 253 core/libs/prx/libSceAgcDriver/Execution/include/Driver/Draw/HeapStages.hpp
core/libs/prx/libSceAgcDriver/Execution/src/Driver/Draw/HeapStages.cpp
core/libs/prx/libSceAgcDriver/Graphics/include/BindlessHeap.hpp
core/libs/prx/libSceAgcDriver/Graphics/include/DescriptorHeapObjects.hpp
core/libs/prx/libSceAgcDriver/Graphics/src/BindlessHeap.cpp
core/libs/prx/libSceAgcDriver/Graphics/src/DescriptorHeapObjects.cpp
core/libs/prx/libSceAgcDriver/tests/BindlessHeapSlots.cpp
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_bindless_images_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_buffer_atomics_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_buffer_format_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_compute_table_calls_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_depth_storage_dispatch_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_dispatch_move_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_draw_data_hit_user_words_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_draw_relocate_user_values_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_fragment_user_data_tail_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_gpu_indirect_arguments_misaligned_writer_ahead_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_gpu_indirect_arguments_written_ahead_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_heap_compute_sample_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_heap_draw_sample_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_heap_slots_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_atomics64_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_atomics_bitwise_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_atomics_float_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_atomics_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_cache_bits_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_gather_one_dimensional_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_load_packed_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_sample_border_color_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_sample_derivatives_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_sample_shared_sampler_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_srgb_load_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_store_array_through_volume_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_store_face_on_cube_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_store_float_rounding_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_store_line_through_plane_array_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_store_line_through_plane_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_store_packed_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_store_sint_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_store_unorm_rounding_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_store_volume_through_array_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_table_cache_bounds_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_texel_status_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_indirect_arguments_written_ahead_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_indirect_patched_stage_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_lds_beyond_device_limit_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_mesh_draw_relocation_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_mesh_index_cache_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_mesh_provoking_vertex_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_pixel_barycentric_emulation_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_rect_list_indirect_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_storage_one_slice_alias_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_tessellation_submit_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_view_past_last_mip_tests.cmake
core/libs/prx/libSceAgcDriver/tests/execution/DeviceFunctionCache.cpp
core/libs/prx/libSceAgcDriver/tests/execution/HeapComputeSample.cpp
core/libs/prx/libSceAgcDriver/tests/execution/HeapDrawSample.cpp
core/libs/prx/libSceAgcDriver/tests/execution/HeapSampleKernel.hpp
core/libs/prx/libSceAgcDriver/tests/execution/HeapTableStageReuse.cpp
core/libs/prx/libSceAgcDriver/tests/execution/TessellationSubmit.cpp
core/shader/recompiler/HeapTemplateBudget.hpp
core/shader/recompiler/tests/HeapTemplateBudgetTests.cpp
PR 254 core/libs/prx/libSceAgcDriver/Execution/include/Driver/Draw/HeapStages.hpp
core/libs/prx/libSceAgcDriver/Execution/src/Driver/Draw/HeapStages.cpp
core/libs/prx/libSceAgcDriver/Graphics/include/BindlessHeap.hpp
core/libs/prx/libSceAgcDriver/Graphics/include/DescriptorHeapObjects.hpp
core/libs/prx/libSceAgcDriver/Graphics/src/BindlessHeap.cpp
core/libs/prx/libSceAgcDriver/Graphics/src/DescriptorHeapObjects.cpp
core/libs/prx/libSceAgcDriver/tests/BindlessHeapSlots.cpp
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_bindless_images_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_buffer_atomics_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_buffer_format_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_compute_table_calls_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_depth_storage_dispatch_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_dispatch_move_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_draw_data_hit_user_words_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_draw_relocate_user_values_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_fragment_user_data_tail_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_gpu_indirect_arguments_misaligned_writer_ahead_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_gpu_indirect_arguments_written_ahead_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_heap_compute_sample_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_heap_draw_sample_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_heap_slots_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_atomics64_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_atomics_bitwise_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_atomics_float_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_atomics_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_cache_bits_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_gather_one_dimensional_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_load_packed_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_sample_border_color_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_sample_derivatives_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_sample_shared_sampler_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_srgb_load_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_store_array_through_volume_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_store_face_on_cube_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_store_float_rounding_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_store_line_through_plane_array_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_store_line_through_plane_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_store_packed_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_store_sint_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_store_unorm_rounding_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_store_volume_through_array_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_table_cache_bounds_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_texel_status_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_indirect_arguments_written_ahead_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_indirect_patched_stage_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_lds_beyond_device_limit_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_mesh_draw_relocation_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_mesh_index_cache_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_mesh_provoking_vertex_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_pixel_barycentric_emulation_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_rect_list_indirect_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_storage_one_slice_alias_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_tessellation_submit_tests.cmake
core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_view_past_last_mip_tests.cmake
core/libs/prx/libSceAgcDriver/tests/execution/DeviceFunctionCache.cpp
core/libs/prx/libSceAgcDriver/tests/execution/HeapComputeSample.cpp
core/libs/prx/libSceAgcDriver/tests/execution/HeapDrawSample.cpp
core/libs/prx/libSceAgcDriver/tests/execution/HeapSampleKernel.hpp
core/libs/prx/libSceAgcDriver/tests/execution/HeapTableStageReuse.cpp
core/libs/prx/libSceAgcDriver/tests/execution/TessellationSubmit.cpp
core/shader/recompiler/HeapTemplateBudget.hpp
core/shader/recompiler/tests/HeapTemplateBudgetTests.cpp
PR 591 core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_bindless_images_tests.cmake
PR 803 core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_bindless_images_tests.cmake
PR 984 core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_mesh_draw_relocation_tests.cmake
PR 1939 core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_image_table_variants_tests.cmake
PR 2157 core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_buffer_format_tests.cmake
PR 2219 core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_bindless_images_tests.cmake
PR 2234 core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_bindless_images_tests.cmake
PR 2366 core/libs/prx/libSceAgcDriver/tests/cmake/agc_driver_bindless_images_tests.cmake

@github-actions github-actions Bot added the needs rebase Conflicts with main, rebase needed label Dec 4, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

needs rebase Conflicts with main, rebase needed

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants