perf(agc): reuse heap mirror reference buffers between builds #8874

Merged
JJenkx merged 10 commits from upstream-pr/8874 into main 2026-11-02 07:57:03 +00:00
JJenkx commented 2026-10-21 03:55:11 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by JJenkx on 2026-10-21T03:55:11Z.


What

Reuse heap-mirror write-back reference buffers instead of allocating fresh storage for every build. ReferenceStorage keeps at most eight idle buffers and 2 GiB, and a take selects the smallest capacity that fits. The reference is resized to the served range before reading resident-mirror bytes; the bytes copied and compared remain unchanged. Take/return allocate no storage and are noexcept; evicted buffers are destroyed after releasing the store lock.

Buffers idle for two seconds are released when the store is polled by take, an eligible return, a heap-mirror sweep or present. This is polled expiry, not a background timer: if none of those operations occurs, expired buffers remain until a later poll or process shutdown. The cap covers idle storage, not active references. The cap and reuse interval remain unmeasured policy choices recorded as debt.

The rebase preserves current main's joined-heap cleanup, resident-mirror growth/readback path, heap-readback clearing and address-copy cap tests. It retains the reviewed pool implementation and tests; the additional documentation commit clarifies the polling limitation.

Tested

Current rebase qualification (2026-10-28)

@oneandonlydean Refreshed on main 2227f1366188cda5699dd20e2e756a18006a5d4b as f31fdef05ba8bf532e19c461e2f758e860aa5fe9, retaining RunAddressCopyCapTests(int frames), adding RunHeapMirrorReferenceSizeTests, and keeping both debt entries. Original topic code/tests and current main gitlinks are preserved.

Linux Release with bundled SPIRV-Tools enabled: main's 16 groups ×3 pass (48), candidate's 18 groups ×3 pass (54), and the restored candidate passes 54 with source and driver byte-identical to its initial build. The main-production GuestBufferMemory.cpp control also passes all 18 groups: this is a compatibility control, not a distinguishing regression for the reuse optimization.

Four groups execute physical RX 6650 XT/RADV Vulkan: host-import unmap, host-import retirement, sparse-run import and sparse-run copied import. Their logs verify Khronos validation insertion (12 per repeated arm; 4 in the single control), zero VUIDs, missing-layer diagnostics or skips. The remaining fixtures use CPU/mock Vulkan, including the new reference-size fixture; their passes are not hardware coverage. An initial all-tests-passing harness attempt was excluded because it incorrectly required real-loader insertion from mock fixtures; it is preserved, and the corrected matched pair is archived.

Complete harnesses and cleanup used the shared FIFO and service-owned PTYs. Conventions and whitespace pass. Ready status is retained. Earlier measured memory/performance results retain their original pins; no new title, Windows, full-suite or speed claim is made.

Exact source/dependency pins, source proof, builds, service/FIFO receipts, controls, logs and JUnit, SHA-256 60998673f17454df73307175ec04830d347894b5a463e00fddd1447d552c781f.

Windows qualification, 2026-10-26: exact public head f7aec2a96626947a8f98dccca567e220d1030039 against pinned main 49d1f9b07ec7f6f989ace1c504bbe9dd6748dcbb, built separately with WinLibs GCC 15.2.0 UCRT r7, Release, Windows 11 Enterprise 10.0.22621, AMD Radeon RX 6700 XT, driver 32.0.21045.16010. This verifies the Windows test-runtime PATH fix: agc_reference_storage and agc_heap_mirror_reference_size each pass three times, and generated CTest metadata prepends the private libs/unpatched directory.

Main passes 16 executed groups × 3 (48 passes); the PR passes 18 × 3 (54 passes). Each selection additionally reports the same single expected skip, agc_host_import_sparse (Linux-only udmabuf imports). agc_heap_mirror_unwatched_import is not registered on Windows. No other skips or failures. Four physical GPU groups per arm each execute three times on the RX 6700 XT with Khronos validation loaded (12 insertions per arm); other selected groups use CPU/mock graphics. Zero VUIDs in either arm and no new VUIDs. Vulkan is required and shader caches disabled.

Both arms use the same private Khronos validation layer 1.4.309, source 3ba0e590a2e76475b3eef4043355b498fb64e752, built with the supported r7 toolchain. Initial attempts with an installed 1.4.363 layer failed to load because its libstdc++ imports were incompatible with r7; those runs are retained as rejected evidence. The final runs verify actual layer loading for every physical GPU repetition.

Exact pins, source manifests, build/test logs, JUnit, CTest runtime metadata, VVL/runtime hashes, rejected-attempt diagnostics and terminal FIFO receipts. SHA-256: 4dc1fd9f52de1e1c4dc25b4bb96e29af74b48700ca34c1a89c8f3546457fcef7; downloaded copy verified. No new title, RSS or performance measurement is claimed.

Current-main refresh, 2026-10-25: head cab138246ad9984df92e6c7427118c2b3cac4fd7, five linear commits on main 49d1f9b07ec7f6f989ace1c504bbe9dd6748dcbb. The four implementation/test commits are rebased, followed by a documentation-only expiry clarification. Production patch lines are unchanged from old public head d3e9e8a780c. Main's joined-heap expiry, resident growth/readback behavior and address-copy cap tests are retained. Source, conventions, whitespace and local merge-tree checks pass.

Linux GCC 16.2.1 Release, Ryzen 9 7950X, RX 6650 XT/RADV Mesa 26.2.4, Arch Linux 7.2.9. Built full libs on both pinned main and candidate, plus main's four/candidate's five selected test executables. Main passes 18 groups × 3 repetitions (54 passes); candidate passes 20 × 3 (60 passes). Zero skips and zero VUID errors. Vulkan is required and shader caches disabled. All four real GPU groups load Khronos validation in each physical repetition (12 insertions per arm); other groups use CPU/mock graphics checks, not physical GPU execution. The matrix includes pool/reference size, heap mirrors, sparse/import lifetimes and current-main address-copy caps.

A negative control delays only ReleaseIdle's clock by the idle interval. agc_reference_storage fails at a buffer idle for the limit was not released. After removing that temporary fault, the full candidate selection passes 60/60 again, zero skips/VUIDs, and the raw driver plus all five tested executable hashes are byte-identical to the first candidate. This verifies the test catches the expiry boundary; it is not a new title RSS observation or proof of a background timer.

Current source patch, preservation checks, full build logs, verbose main/candidate/control/restoration logs and hashes. SHA-256: de1b6160e76668c554c0738012a48121a51909c809ca104d3a8d714996fe1271; downloaded copy verified.

That Linux refresh included no fresh title, RSS, performance, Windows or full-suite run; the later Windows qualification is recorded above. Historical speed/RSS measurements below retain their original exact integration pins. The prior RSS scene kept using heap mirrors and did not exercise idle release; no measured release-induced RSS drop is established. The current description/debt explicitly correct the earlier implication of unconditional two-second expiry: release requires a subsequent poll.

Historical performance, RSS and earlier correctness evidence

  • Earlier tested head 082f3eceb9 (2906f2ac44 change + 082f3eceb9 test) on main 990f45e17d, prepared and gated by another AI worker on this machine (claude-research) and pushed here. Main had merged #7647 (resident heap mirrors), and the rebase keeps its semantics:
    • takeHeapReferences calls growResident, then takes reusable storage.
    • A resident mirror's bytes are read into that storage with resident->Read; otherwise they are assigned from the buffer.
    • heapReadbacks is still cleared where main clears it.
    • Both new tests are kept beside main's new agc_sparse_heap_mirror_budget.
    • It merged cleanly into the main revision tested in that earlier report.
  • Focused gate on that exact head: ANYPS5_REQUIRE_VULKAN=1 ANYPS5_NO_SHADER_CACHE=1 VK_INSTANCE_LAYERS=VK_LAYER_KHRONOS_validation VK_LOADER_DEBUG=layer ctest -V -j1 -R '^(agc_driver_graphics|agc_sparse_.*|agc_heap_mirror_.*|agc_host_import.*|agc_reference_storage)$'. Result: 18/18 pass, validation layer 1.4.363 inserted in 4 tests, 0 VUIDs.
    • On the previous head (404aab2817 on 9af7d8d810), main passed 15/15 and this PR 17/17, both with 4 layer insertions and 0 VUIDs. The new tests also pass with GuestBufferMemory taken from main. That is expected: reuse changes no observable bytes, and the tests check that reused storage is correct (sizes and contents), not that reuse happens.
    • Logs: https://github.com/JJenkx/AnyPS5/releases/tag/pr8874-evidence
  • Performance: controlled Code Violet (PPSA26528) run by another AI worker on this machine (claude-research). Details: https://github.com/boykopovar/AnyPS5/pull/8874#issuecomment-6359360025
    • Integration-relative: on RADV, plain main does not render the title (#6256). Control ddeeddfff4 is main 1a745ae38e + #4449 + #8908 + a local fd guard. The candidate 6208617c95 is control + this PR at 317d528af7, an earlier head with the same 9-file change.
    • Eight terminal-attached arms in alternating order (control, PR, PR, control, PR, control, control, PR). The seeds (shader cache, Mesa cache, writable download0) were restored and hash-checked before every arm. 300 s at the title screen, APS5_TRACE_SECONDS=240:30, no dropped trace events.
    • Results:
      • Resources.Complete: control 2038-2506 vs PR 1283-1985 ms/frame, no overlap; medians 2316 vs 1552.
      • frame p90: control 4205-5427 vs PR 2236-3490 ms, no overlap.
      • Frame p50 overlaps, so no p50 change is claimed. The title stays under 1 FPS on both sides.
    • Summary JSON lines, in run order:
{"commit": "ddeeddfff4ca", "dirty": false, "env": {"APS5_PAD_INPUT_FILE": "<path>", "APS5_TRACE_EVENTS": "4194304", "APS5_TRACE_SECONDS": "240:30"}, "gpu": "AMD Radeon RX 6650 XT (RADV NAVI23)", "driver": "radv Mesa 26.2.4-arch1.1", "os": "Linux 7.2.9-arch1-1", "cpu": "AMD Ryzen 9 7950X 16-Core Processor", "cpu_threads": 32, "memory_mib": 127901, "title_id": "PPSA26528", "title": "Code Violet", "content_version": "01.000.028", "resolution": "3840x2160", "window": {"spec": "seconds 240:30", "first_present": 156, "ms": 30640.15}, "presents": 10, "frame_ms": {"p50": 3992.296, "p90": 5427.294, "p99": 5427.294, "max": 5427.294}, "gpu_busy_ms_per_present": 744.568, "worker_busy_pct": {"queue worker 0x0": 99.936, "queue worker 0x20": 98.571}, "top_phases_ms_per_frame": {"Driver.Packet": 6081.167, "Driver.Packet.dispatch": 3315.598, "Driver.Dispatch": 3314.242, "Vulkan.Dispatch": 2437.039, "Vulkan.Dispatch.shader_resources": 2427.172, "Resources.Complete": 2421.096, "Driver.Packet.memory_wait": 1878.356, "GpuMutex.wait.hook": 1015.725}, "trace_dropped": false, "trace": "aps5-trace-ddeeddfff4ca-2886059.json.gz"}
{"commit": "6208617c95f1", "dirty": false, "env": {"APS5_PAD_INPUT_FILE": "<path>", "APS5_TRACE_EVENTS": "4194304", "APS5_TRACE_SECONDS": "240:30"}, "gpu": "AMD Radeon RX 6650 XT (RADV NAVI23)", "driver": "radv Mesa 26.2.4-arch1.1", "os": "Linux 7.2.9-arch1-1", "cpu": "AMD Ryzen 9 7950X 16-Core Processor", "cpu_threads": 32, "memory_mib": 127901, "title_id": "PPSA26528", "title": "Code Violet", "content_version": "01.000.028", "resolution": "3840x2160", "window": {"spec": "seconds 240:30", "first_present": 181, "ms": 30888.713}, "presents": 15, "frame_ms": {"p50": 1757.209, "p90": 2984.839, "p99": 3937.0, "max": 3937.0}, "gpu_busy_ms_per_present": 682.819, "worker_busy_pct": {"queue worker 0x0": 99.922, "queue worker 0x20": 99.501}, "top_phases_ms_per_frame": {"Driver.Packet": 4106.071, "Driver.Packet.dispatch": 2124.983, "Driver.Dispatch": 2121.846, "Vulkan.Dispatch": 1540.429, "Vulkan.Dispatch.shader_resources": 1532.391, "Resources.Complete": 1529.579, "Driver.Packet.memory_wait": 1302.325, "GpuMutex.wait.hook": 654.578}, "trace_dropped": false, "trace": "aps5-trace-6208617c95f1-3013032.json.gz"}
{"commit": "6208617c95f1", "dirty": false, "env": {"APS5_PAD_INPUT_FILE": "<path>", "APS5_TRACE_EVENTS": "4194304", "APS5_TRACE_SECONDS": "240:30"}, "gpu": "AMD Radeon RX 6650 XT (RADV NAVI23)", "driver": "radv Mesa 26.2.4-arch1.1", "os": "Linux 7.2.9-arch1-1", "cpu": "AMD Ryzen 9 7950X 16-Core Processor", "cpu_threads": 32, "memory_mib": 127901, "title_id": "PPSA26528", "title": "Code Violet", "content_version": "01.000.028", "resolution": "3840x2160", "window": {"spec": "seconds 240:30", "first_present": 186, "ms": 31288.173}, "presents": 17, "frame_ms": {"p50": 1900.036, "p90": 2236.123, "p99": 2340.754, "max": 2340.754}, "gpu_busy_ms_per_present": 674.571, "worker_busy_pct": {"queue worker 0x0": 99.905, "queue worker 0x20": 98.584}, "top_phases_ms_per_frame": {"Driver.Packet": 3651.607, "Driver.Packet.dispatch": 1825.097, "Driver.Dispatch": 1824.09, "Vulkan.Dispatch": 1312.238, "Vulkan.Dispatch.shader_resources": 1303.662, "Resources.Complete": 1286.777, "Driver.Packet.memory_wait": 1254.13, "GpuMutex.wait.hook": 680.343}, "trace_dropped": false, "trace": "aps5-trace-6208617c95f1-3133785.json.gz"}
{"commit": "ddeeddfff4ca", "dirty": false, "env": {"APS5_PAD_INPUT_FILE": "<path>", "APS5_TRACE_EVENTS": "4194304", "APS5_TRACE_SECONDS": "240:30"}, "gpu": "AMD Radeon RX 6650 XT (RADV NAVI23)", "driver": "radv Mesa 26.2.4-arch1.1", "os": "Linux 7.2.9-arch1-1", "cpu": "AMD Ryzen 9 7950X 16-Core Processor", "cpu_threads": 32, "memory_mib": 127901, "title_id": "PPSA26528", "title": "Code Violet", "content_version": "01.000.028", "resolution": "3840x2160", "window": {"spec": "seconds 240:30", "first_present": 161, "ms": 34131.142}, "presents": 11, "frame_ms": {"p50": 2962.007, "p90": 4727.645, "p99": 5025.638, "max": 5025.638}, "gpu_busy_ms_per_present": 656.36, "worker_busy_pct": {"queue worker 0x0": 99.943, "queue worker 0x20": 99.06}, "top_phases_ms_per_frame": {"Driver.Packet": 6174.132, "Driver.Packet.dispatch": 3751.391, "Driver.Dispatch": 3750.419, "Vulkan.Dispatch": 2526.365, "Vulkan.Dispatch.shader_resources": 2517.92, "Resources.Complete": 2509.58, "Driver.Packet.memory_wait": 1551.969, "GpuMutex.wait.dispatch": 997.572}, "trace_dropped": false, "trace": "aps5-trace-ddeeddfff4ca-3247948.json.gz"}
{"commit": "6208617c95f1", "dirty": false, "env": {"APS5_PAD_INPUT_FILE": "<path>", "APS5_TRACE_EVENTS": "4194304", "APS5_TRACE_SECONDS": "240:30"}, "gpu": "AMD Radeon RX 6650 XT (RADV NAVI23)", "driver": "radv Mesa 26.2.4-arch1.1", "os": "Linux 7.2.9-arch1-1", "cpu": "AMD Ryzen 9 7950X 16-Core Processor", "cpu_threads": 32, "memory_mib": 127901, "title_id": "PPSA26528", "title": "Code Violet", "content_version": "01.000.028", "resolution": "3840x2160", "window": {"spec": "seconds 240:30", "first_present": 179, "ms": 30629.534}, "presents": 12, "frame_ms": {"p50": 2407.655, "p90": 3490.165, "p99": 4600.331, "max": 4600.331}, "gpu_busy_ms_per_present": 684.304, "worker_busy_pct": {"queue worker 0x0": 99.934, "queue worker 0x20": 99.217}, "top_phases_ms_per_frame": {"Driver.Packet": 5081.035, "Driver.Packet.dispatch": 2921.691, "Driver.Dispatch": 2920.738, "Vulkan.Dispatch": 2002.647, "Vulkan.Dispatch.shader_resources": 1994.514, "Resources.Complete": 1988.964, "Driver.Packet.memory_wait": 1505.24, "GpuMutex.wait.hook": 722.85}, "trace_dropped": false, "trace": "aps5-trace-6208617c95f1-3364695.json.gz"}
{"commit": "ddeeddfff4ca", "dirty": false, "env": {"APS5_PAD_INPUT_FILE": "<path>", "APS5_TRACE_EVENTS": "4194304", "APS5_TRACE_SECONDS": "240:30"}, "gpu": "AMD Radeon RX 6650 XT (RADV NAVI23)", "driver": "radv Mesa 26.2.4-arch1.1", "os": "Linux 7.2.9-arch1-1", "cpu": "AMD Ryzen 9 7950X 16-Core Processor", "cpu_threads": 32, "memory_mib": 127901, "title_id": "PPSA26528", "title": "Code Violet", "content_version": "01.000.028", "resolution": "3840x2160", "window": {"spec": "seconds 240:30", "first_present": 154, "ms": 31370.837}, "presents": 12, "frame_ms": {"p50": 3309.874, "p90": 4205.095, "p99": 4248.044, "max": 4248.044}, "gpu_busy_ms_per_present": 631.648, "worker_busy_pct": {"queue worker 0x0": 99.935, "queue worker 0x20": 98.603}, "top_phases_ms_per_frame": {"Driver.Packet": 5189.17, "Driver.Packet.dispatch": 3007.904, "Driver.Dispatch": 3006.72, "Vulkan.Dispatch": 2084.577, "Vulkan.Dispatch.shader_resources": 2075.89, "Resources.Complete": 2042.26, "Driver.Packet.memory_wait": 1379.514, "GpuMutex.wait.hook": 804.84}, "trace_dropped": false, "trace": "aps5-trace-ddeeddfff4ca-3481320.json.gz"}
{"commit": "ddeeddfff4ca", "dirty": false, "env": {"APS5_PAD_INPUT_FILE": "<path>", "APS5_TRACE_EVENTS": "4194304", "APS5_TRACE_SECONDS": "240:30"}, "gpu": "AMD Radeon RX 6650 XT (RADV NAVI23)", "driver": "radv Mesa 26.2.4-arch1.1", "os": "Linux 7.2.9-arch1-1", "cpu": "AMD Ryzen 9 7950X 16-Core Processor", "cpu_threads": 32, "memory_mib": 127901, "title_id": "PPSA26528", "title": "Code Violet", "content_version": "01.000.028", "resolution": "3840x2160", "window": {"spec": "seconds 240:30", "first_present": 159, "ms": 30481.98}, "presents": 11, "frame_ms": {"p50": 2036.421, "p90": 4246.281, "p99": 4663.05, "max": 4663.05}, "gpu_busy_ms_per_present": 810.726, "worker_busy_pct": {"queue worker 0x0": 99.94, "queue worker 0x20": 98.922}, "top_phases_ms_per_frame": {"Driver.Packet": 5510.018, "Driver.Packet.dispatch": 3208.028, "Driver.Dispatch": 3206.827, "Vulkan.Dispatch": 2244.751, "Vulkan.Dispatch.shader_resources": 2236.138, "Resources.Complete": 2217.781, "Driver.Packet.memory_wait": 1452.236, "GpuMutex.wait.hook": 829.56}, "trace_dropped": false, "trace": "aps5-trace-ddeeddfff4ca-3599341.json.gz"}
{"commit": "6208617c95f1", "dirty": false, "env": {"APS5_PAD_INPUT_FILE": "<path>", "APS5_TRACE_EVENTS": "4194304", "APS5_TRACE_SECONDS": "240:30"}, "gpu": "AMD Radeon RX 6650 XT (RADV NAVI23)", "driver": "radv Mesa 26.2.4-arch1.1", "os": "Linux 7.2.9-arch1-1", "cpu": "AMD Ryzen 9 7950X 16-Core Processor", "cpu_threads": 32, "memory_mib": 127901, "title_id": "PPSA26528", "title": "Code Violet", "content_version": "01.000.028", "resolution": "3840x2160", "window": {"spec": "seconds 240:30", "first_present": 178, "ms": 32057.776}, "presents": 15, "frame_ms": {"p50": 2021.931, "p90": 2604.798, "p99": 4700.152, "max": 4700.152}, "gpu_busy_ms_per_present": 718.208, "worker_busy_pct": {"queue worker 0x0": 99.923, "queue worker 0x20": 98.767}, "top_phases_ms_per_frame": {"Driver.Packet": 4245.321, "Driver.Packet.dispatch": 2323.912, "Driver.Dispatch": 2322.844, "Vulkan.Dispatch": 1614.889, "Vulkan.Dispatch.shader_resources": 1607.154, "Resources.Complete": 1582.581, "Driver.Packet.memory_wait": 1307.953, "GpuMutex.wait.hook": 696.814}, "trace_dropped": false, "trace": "aps5-trace-6208617c95f1-3716801.json.gz"}
  • Earlier observations, kept for the record (not controlled evidence):

    • Base main 9f4ddf7cf9; this branch has the change cc53b45601 and a test commit 317d528af7.
    • New agc_reference_storage (CPU): empty store, reuse of the same allocation, smallest fit, eviction of the oldest by byte limit and by slot count (checked against the identities of the retained buffers), oversize storage, and Return/eviction/Take with the allocation-failure countdown armed (still armed afterwards, byte count consistent). A store whose eviction allocates terminates the test with std::bad_alloc.
    • ctest -R 'heap_mirror|sparse_heap|reference_storage|bda|guest_memory_lifetime|sparse' -V on main and on this PR, same machine and GPU, ANYPS5_REQUIRE_VULKAN=1, ANYPS5_NO_SHADER_CACHE=1, VK_INSTANCE_LAYERS=VK_LAYER_KHRONOS_validation (layer 1.4.363 loaded; neither log reports was not found but was requested): main (9f4ddf7cf9) 28/29, PR (cc53b45601) 29/30 (the extra test is the new one). Both fail agc_driver_guest_memory_lifetime the same way (radv/amdgpu: The CS has been rejected (-14), guest prefix unmap failed), and both logs hold the same validation errors: 2 × VUID-vkCmdCopyBuffer-srcBuffer-00118, 2 × VUID-vkResetFences-pFences-01123. No new VUID-.
    • Diagnostic observations, not controlled performance evidence. Integration build, not unmodified main: Echoes of the End PPSA25636 01.012.000 stops after about 30 s on main, so both sides are main 33a6d6bbfb + #8089 + #8762 + #8091 + #4449, without and with this commit. Unattended start to the loading screen, no input, one runtime directory for every run: the shader and pipeline cache directory is shared, so initial cache contents are not matched between runs, and no speedup is claimed from these lines. Ryzen 9 7950X, RX 6650 XT, RADV Mesa 26.2.4, Linux 7.2.9. Order base, PR, PR, base:

    Before (integration 8a251ef745):
    seconds 40:60 from present 340: 11 presents, frame p50 5867.4 / p90 7221.6 / p99 7377.7 / max 7377.7 ms, GPU busy 543.2 ms per present
    seconds 40:60 from present 351: 11 presents, frame p50 5427.9 / p90 6189.5 / p99 7141.4 / max 7141.4 ms, GPU busy 497.8 ms per present

    After (integration + this PR, 6e0a219cbe):
    seconds 40:60 from present 343: 15 presents, frame p50 4069.4 / p90 5171.4 / p99 5460.5 / max 5460.5 ms, GPU busy 497.8 ms per present
    seconds 40:60 from present 348: 16 presents, frame p50 4004.1 / p90 4933.0 / p99 5394.2 / max 5394.2 ms, GPU busy 479.7 ms per present

    The title still loads at well under 1 FPS on both sides. The captures ran on an integration with the earlier base 33a6d6bbfb; the PR commit was cherry-picked onto it (6e0a219cbe). Traces, logs, screenshots, profiles and validation logs: evidence archive (SHA-256 00bbfd328cc0ecbed29aedd3925217dc6e39a9a018170bd941549b5146af27be).

    • Second title, neutral observation, no improvement claimed: Mortal Shell II PPSA34008, measured by another worker on the same machine and scene, APS5_TRACE_SECONDS=150:30, one run each, separate relinked runtimes, initial shader/pipeline cache state not reported as matched. Base main e0e57a3270 + #8839 (641fce5c84), change = base + this PR (91d0f400ba):

    Before: seconds 150:30 from present 26: 6 presents, frame p50 4885.1 / p90 7341.3 / p99 7341.3 / max 7341.3 ms, GPU busy 186.3 ms per present
    After: seconds 150:30 from present 40: 6 presents, frame p50 5074.1 / p90 5685.3 / p99 5685.3 / max 5685.3 ms, GPU busy 178.7 ms per present

    Resources.Complete 5.29 vs 5.14 ms per dispatch: no measurable change in that title, where the per-dispatch cost is the copy and the WriteChanged compare that this PR keeps. Traces (SHA-256 4412bd6c74fc8493e765d3d33b970a6b947ef900e09e6a38384d0ebc4f659c25).

    • Review: agc_heap_mirror_reference_size (317d528af7) checks a smaller reference written back after a larger one reused its storage; with takeHeapReferences keeping the storage's capacity as its size it fails with heap mirror write-back has no reference.
    • python3 tools/check_conventions.py --base origin/main passes. The overlap tool reports #8016 and #7647, which rewrite the same reference construction for device-local and resident heap mirrors; they do not reuse storage, and whichever lands later rebases onto the other.

Supplemental exact-head qualification — 2026-10-31

Merged main 602c0e417ca11f53de54ffe7b3253e95cb93c0d4 into previous head 0ae75877c9cb6238c59a6894f527cfe3221b42ee, retaining the complete original history. New public head: e21b872338378862bd71db9b3d22de26b8a7dcea.

The sole conflict was adjacent includes in Recorder.cpp; both main's DepthSurface.hpp and this PR's ReferenceStorage.hpp remain. The topic's added/removed lines are identical to its patch against 08a10d225306; main's newer behavior, fixtures, debt and submodule pins remain. Conventions and whitespace checks pass. Fresh main 85cdddc1b0e89fe66744f437513ccfdcb16f72f6 changes no AGC/shader paths after the tested pin, and its merge preview is clean.

Paired focused gate, Release with SPIRV-Tools ON, AMD Radeon RX 6650 XT / RADV Mesa 26.2.6, Linux 7.2.11-arch1-1. Same selected groups as the earlier focused gate; one execution per group:

Arm Result Actual Khronos layer insertions VUIDs Skips
main 602c0e417ca 16/16 passed 4 0 0
change e21b8723383 18/18 passed 4 0 0

The change adds agc_reference_storage and agc_heap_mirror_reference_size. Both arms used ANYPS5_REQUIRE_VULKAN=1, ANYPS5_NO_SHADER_CACHE=1, VK_INSTANCE_LAYERS=VK_LAYER_KHRONOS_validation and verbose CTest. Neither log reports the requested layer missing. The physical groups are agc_host_import_unmap, agc_host_import_retirement, agc_sparse_run_import and agc_sparse_run_import_copied; the remaining groups use CPU/mock Vulkan. The complete build/test harnesses ran through FIFO tickets1925/1926 under the explicitly title-free infrastructure reservation PPSA00004, now released.

Qualification detail: both CTest commands exited0 and their JUnit files report every selected group passed. The wrapper then exited1 because its postprocessor incorrectly required physical-layer insertion in CPU/mock agc_driver_graphics. The original failed wrapper receipts are retained. A separate audit (audit-raw.py, paired-raw-audit.json) validates the unchanged raw logs/JUnit against the actual four physical groups; no source or test behavior was changed, and no rerun is claimed.

This maintenance adds no title capture or performance/RSS claim. The earlier matched capture remains inconclusive (comment6524722530). Existing external NVIDIA/Windows and older AMD evidence remains tied to its original pins and scope.

Evidence: immutable source and paired GPU receipts (SHA-256 5d3548a127cb5d60199c18cff61e1d7df947fa5923d79a73f33dc116311f01e3, download verified).

AI-assisted: yes.

Supplemental qualification (2026-11-01)

Merged current main 93dbd0f82aea684e95f15f06e7d42c0064af18cf into previous head e21b872338378862bd71db9b3d22de26b8a7dcea. New public head: de5afa814417a3123cb5f5388ae982bda52477ce.

The conflicts were main's AGC CMake test split, the heap-mirror sweep signature and adjacent debt entries. Kept main's sweepMirrors(neededBytes, protectAddress) behavior and the PR's ReferenceStorage::Shared().ReleaseIdle() poll; moved the PR's target/test registrations into the corresponding new CMake fragments. Kept main's updated host-import budget entry and this PR's storage-limit debt. All nonblank topic added/removed lines are identical to the previous topic patch; complete original history and main's gitlinks are retained. Conventions and whitespace pass.

Paired focused Release gates, SPIRV-Tools ON, AMD Radeon RX 6650 XT / RADV Mesa26.2.6, Linux7.2.11-arch1-1, one execution per group:

Arm Focused groups Actual Khronos insertions VUIDs Skips
main 93dbd0f82aea 16/16 pass 4 0 0
PR de5afa814417 18/18 pass 4 0 0

Both ran verbose CTest with ANYPS5_REQUIRE_VULKAN=1 ANYPS5_NO_SHADER_CACHE=1 VK_INSTANCE_LAYERS=VK_LAYER_KHRONOS_validation, and neither reports the requested layer missing. Four host-import/sparse-run groups execute on the physical GPU; the other groups use CPU/mock Vulkan. The PR adds the reference-storage and reference-size regressions. Whole isolated build/test harnesses ran through the title-free PPSA00004 infrastructure reservation/FIFO (main2487, change2489), with service-owned PTYs; both wrappers and CTest exited0. A prior candidate ticket2486 was cancelled while queued, before execution, to remove a blank EOF in the new fragment; that receipt is retained.

No new title capture, FPS, allocation or RSS claim. The previously matched title capture remains inconclusive (comment6524722530); historical Windows/NVIDIA/AMD reports retain their own pins/scopes.

Evidence: frozen source and qualification receipts (SHA-256 44a57b5d68d03b34fa53d61a4e20e2c54316d4ff607c86c66e0f99cf14723ae8, downloaded bytes and internal manifest verified).
AI-assisted: yes.

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
  • Generic behaviour, not specific to one title
  • Depends on: none
  • Fixes: none
  • Unblocks: none
  • GPUs tested: AMD Radeon RX 6650 XT, RADV Mesa 26.2.4, Arch Linux 7.2.9-arch1-1; AMD Radeon RX 6700 XT, Windows 11 Enterprise 10.0.22621, AMD 32.0.21045.16010; NVIDIA RTX 2000 Ada Generation, driver 595.99.02, Ubuntu 26.04.1 LTS (external exact-head report below).; AMD Radeon RX 6650 XT, RADV Mesa 26.2.6, Linux 7.2.11-arch1-1 (current paired focused tests)
  • AI-assisted: yes

Contributor-reported attribution observation: @milescoviello measured Borderlands 4 PPSA01494 on RTX 4070 Ti / NVIDIA 615.71.09, Linux, warm shader cache, 600 s, with local phase counters. Their candidate is main cbee224804 plus this head f7aec2a966 and #9858, so this is a mixed integration. The after-region upload phase averaged about 71 ms on control versus 27 ms on candidate; total slow-upload counts and other phase costs differed. This supports investigating heap-reference/flush cost, but single runs with an extra PR do not isolate this PR's frame-time effect or establish an FPS gain. No new local title run is claimed. Original report and full limits.

External NVIDIA validation (2026-10-30)

TechLevelZero’s report tested exact head 0ae75877c9cb6238c59a6894f527cfe3221b42ee merged onto main 98ddd9c: Release with SPIRV-Tools enabled built successfully; 2,367 tests passed, four failed (all already failing or unstable on main), and 41 skipped, from 2,412 selected. The report records 905 GPU tests with no new validation IDs; four existing IDs remain. agc_heap_mirror_reference_size and agc_reference_storage were validated without a matching main validation pass, and the job-manager capacity test needed a retry. This is attributed external evidence, not a new local run. Hardware: NVIDIA RTX 2000 Ada Generation, driver 595.99.02, Vulkan 1.4.329; Ubuntu 26.04.1 LTS, kernel 7.0.0-38-generic, Ubuntu 24.04 container.

<!-- greyfinch-sync:boykopovar/AnyPS5:issue:4946145398 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/8874). Originally posted by [JJenkx](https://github.com/JJenkx) on 2026-10-21T03:55:11Z. --- ### What Reuse heap-mirror write-back reference buffers instead of allocating fresh storage for every build. `ReferenceStorage` keeps at most eight idle buffers and 2 GiB, and a take selects the smallest capacity that fits. The reference is resized to the served range before reading resident-mirror bytes; the bytes copied and compared remain unchanged. Take/return allocate no storage and are `noexcept`; evicted buffers are destroyed after releasing the store lock. Buffers idle for two seconds are released when the store is polled by take, an eligible return, a heap-mirror sweep or present. **This is polled expiry, not a background timer:** if none of those operations occurs, expired buffers remain until a later poll or process shutdown. The cap covers idle storage, not active references. The cap and reuse interval remain unmeasured policy choices recorded as debt. The rebase preserves current main's joined-heap cleanup, resident-mirror growth/readback path, heap-readback clearing and address-copy cap tests. It retains the reviewed pool implementation and tests; the additional documentation commit clarifies the polling limitation. ### Tested <!-- codex-graphics-refresh-20261028-repeat-pr8874 --> **Current rebase qualification (2026-10-28)** @oneandonlydean Refreshed on main `2227f1366188cda5699dd20e2e756a18006a5d4b` as `f31fdef05ba8bf532e19c461e2f758e860aa5fe9`, retaining `RunAddressCopyCapTests(int frames)`, adding `RunHeapMirrorReferenceSizeTests`, and keeping both debt entries. Original topic code/tests and current main gitlinks are preserved. Linux Release with bundled SPIRV-Tools enabled: main's 16 groups ×3 pass (**48**), candidate's 18 groups ×3 pass (**54**), and the restored candidate passes **54** with source and driver byte-identical to its initial build. The main-production `GuestBufferMemory.cpp` control also passes all 18 groups: this is a compatibility control, not a distinguishing regression for the reuse optimization. Four groups execute physical RX 6650 XT/RADV Vulkan: host-import unmap, host-import retirement, sparse-run import and sparse-run copied import. Their logs verify Khronos validation insertion (12 per repeated arm; 4 in the single control), zero VUIDs, missing-layer diagnostics or skips. The remaining fixtures use CPU/mock Vulkan, including the new reference-size fixture; their passes are not hardware coverage. An initial all-tests-passing harness attempt was excluded because it incorrectly required real-loader insertion from mock fixtures; it is preserved, and the corrected matched pair is archived. Complete harnesses and cleanup used the shared FIFO and service-owned PTYs. Conventions and whitespace pass. Ready status is retained. Earlier measured memory/performance results retain their original pins; no new title, Windows, full-suite or speed claim is made. [Exact source/dependency pins, source proof, builds, service/FIFO receipts, controls, logs and JUnit](https://github.com/JJenkx/AnyPS5/releases/download/linux-validation-20261023/pr8874-f31fdef0-main2227-linux-20261028-repeat.tar.gz), SHA-256 `60998673f17454df73307175ec04830d347894b5a463e00fddd1447d552c781f`. <!-- OS, title or homebrew, what was checked. "Not tested" is a valid answer. A performance change: the summary lines of main and of this PR from the same machine and scene, with the traces attached, captured as the Performance report issue form describes. --> <!-- codex-windows-validation-20261026-pr8874 --> **Windows qualification, 2026-10-26:** exact public head `f7aec2a96626947a8f98dccca567e220d1030039` against pinned main `49d1f9b07ec7f6f989ace1c504bbe9dd6748dcbb`, built separately with WinLibs GCC 15.2.0 UCRT r7, Release, Windows 11 Enterprise 10.0.22621, AMD Radeon RX 6700 XT, driver 32.0.21045.16010. This verifies the Windows test-runtime PATH fix: `agc_reference_storage` and `agc_heap_mirror_reference_size` each pass three times, and generated CTest metadata prepends the private `libs/unpatched` directory. Main passes **16 executed groups × 3 (48 passes)**; the PR passes **18 × 3 (54 passes)**. Each selection additionally reports the same single expected skip, `agc_host_import_sparse` (Linux-only udmabuf imports). `agc_heap_mirror_unwatched_import` is not registered on Windows. No other skips or failures. Four physical GPU groups per arm each execute three times on the RX 6700 XT with Khronos validation loaded (**12 insertions per arm**); other selected groups use CPU/mock graphics. Zero VUIDs in either arm and no new VUIDs. Vulkan is required and shader caches disabled. Both arms use the same private Khronos validation layer 1.4.309, source `3ba0e590a2e76475b3eef4043355b498fb64e752`, built with the supported r7 toolchain. Initial attempts with an installed 1.4.363 layer failed to load because its libstdc++ imports were incompatible with r7; those runs are retained as rejected evidence. The final runs verify actual layer loading for every physical GPU repetition. [Exact pins, source manifests, build/test logs, JUnit, CTest runtime metadata, VVL/runtime hashes, rejected-attempt diagnostics and terminal FIFO receipts](https://github.com/JJenkx/AnyPS5/releases/download/linux-validation-20261023/pr8874-qualified-windows-20261026.tar.gz). SHA-256: `4dc1fd9f52de1e1c4dc25b4bb96e29af74b48700ca34c1a89c8f3546457fcef7`; downloaded copy verified. No new title, RSS or performance measurement is claimed. **Current-main refresh, 2026-10-25:** head `cab138246ad9984df92e6c7427118c2b3cac4fd7`, five linear commits on main `49d1f9b07ec7f6f989ace1c504bbe9dd6748dcbb`. The four implementation/test commits are rebased, followed by a documentation-only expiry clarification. Production patch lines are unchanged from old public head `d3e9e8a780c`. Main's joined-heap expiry, resident growth/readback behavior and address-copy cap tests are retained. Source, conventions, whitespace and local merge-tree checks pass. Linux GCC 16.2.1 Release, Ryzen 9 7950X, RX 6650 XT/RADV Mesa 26.2.4, Arch Linux 7.2.9. Built full `libs` on both pinned main and candidate, plus main's four/candidate's five selected test executables. Main passes **18 groups × 3 repetitions (54 passes)**; candidate passes **20 × 3 (60 passes)**. Zero skips and zero VUID errors. Vulkan is required and shader caches disabled. All four real GPU groups load Khronos validation in each physical repetition (12 insertions per arm); other groups use CPU/mock graphics checks, not physical GPU execution. The matrix includes pool/reference size, heap mirrors, sparse/import lifetimes and current-main address-copy caps. A negative control delays only `ReleaseIdle`'s clock by the idle interval. `agc_reference_storage` fails at `a buffer idle for the limit was not released`. After removing that temporary fault, the full candidate selection passes **60/60** again, zero skips/VUIDs, and the raw driver plus all five tested executable hashes are byte-identical to the first candidate. This verifies the test catches the expiry boundary; it is not a new title RSS observation or proof of a background timer. [Current source patch, preservation checks, full build logs, verbose main/candidate/control/restoration logs and hashes](https://github.com/JJenkx/AnyPS5/releases/download/linux-validation-20261023/pr8874-headcab13824-main49d-pool-validation.tar.gz). SHA-256: `de1b6160e76668c554c0738012a48121a51909c809ca104d3a8d714996fe1271`; downloaded copy verified. That Linux refresh included no fresh title, RSS, performance, Windows or full-suite run; the later Windows qualification is recorded above. Historical speed/RSS measurements below retain their original exact integration pins. The prior RSS scene kept using heap mirrors and did not exercise idle release; no measured release-induced RSS drop is established. The current description/debt explicitly correct the earlier implication of unconditional two-second expiry: release requires a subsequent poll. ### Historical performance, RSS and earlier correctness evidence - **Earlier tested head** `082f3eceb9` (`2906f2ac44` change + `082f3eceb9` test) on `main` `990f45e17d`, prepared and gated by another AI worker on this machine (claude-research) and pushed here. Main had merged #7647 (resident heap mirrors), and the rebase keeps its semantics: - `takeHeapReferences` calls `growResident`, then takes reusable storage. - A resident mirror's bytes are read into that storage with `resident->Read`; otherwise they are assigned from the buffer. - `heapReadbacks` is still cleared where `main` clears it. - Both new tests are kept beside `main`'s new `agc_sparse_heap_mirror_budget`. - It merged cleanly into the main revision tested in that earlier report. - Focused gate on that exact head: `ANYPS5_REQUIRE_VULKAN=1 ANYPS5_NO_SHADER_CACHE=1 VK_INSTANCE_LAYERS=VK_LAYER_KHRONOS_validation VK_LOADER_DEBUG=layer ctest -V -j1 -R '^(agc_driver_graphics|agc_sparse_.*|agc_heap_mirror_.*|agc_host_import.*|agc_reference_storage)$'`. Result: 18/18 pass, validation layer 1.4.363 inserted in 4 tests, 0 VUIDs. - On the previous head (`404aab2817` on `9af7d8d810`), `main` passed 15/15 and this PR 17/17, both with 4 layer insertions and 0 VUIDs. The new tests also pass with `GuestBufferMemory` taken from `main`. That is expected: reuse changes no observable bytes, and the tests check that reused storage is correct (sizes and contents), not that reuse happens. - Logs: https://github.com/JJenkx/AnyPS5/releases/tag/pr8874-evidence - **Performance: controlled Code Violet (PPSA26528) run** by another AI worker on this machine (claude-research). Details: https://github.com/boykopovar/AnyPS5/pull/8874#issuecomment-6359360025 - Integration-relative: on RADV, plain `main` does not render the title (#6256). Control `ddeeddfff4` is `main` `1a745ae38e` + #4449 + #8908 + a local fd guard. The candidate `6208617c95` is control + this PR at `317d528af7`, an earlier head with the same 9-file change. - Eight terminal-attached arms in alternating order (control, PR, PR, control, PR, control, control, PR). The seeds (shader cache, Mesa cache, writable `download0`) were restored and hash-checked before every arm. 300 s at the title screen, `APS5_TRACE_SECONDS=240:30`, no dropped trace events. - Results: - `Resources.Complete`: control 2038-2506 vs PR 1283-1985 ms/frame, no overlap; medians 2316 vs 1552. - frame p90: control 4205-5427 vs PR 2236-3490 ms, no overlap. - Frame p50 overlaps, so no p50 change is claimed. The title stays under 1 FPS on both sides. - Summary JSON lines, in run order: ``` {"commit": "ddeeddfff4ca", "dirty": false, "env": {"APS5_PAD_INPUT_FILE": "<path>", "APS5_TRACE_EVENTS": "4194304", "APS5_TRACE_SECONDS": "240:30"}, "gpu": "AMD Radeon RX 6650 XT (RADV NAVI23)", "driver": "radv Mesa 26.2.4-arch1.1", "os": "Linux 7.2.9-arch1-1", "cpu": "AMD Ryzen 9 7950X 16-Core Processor", "cpu_threads": 32, "memory_mib": 127901, "title_id": "PPSA26528", "title": "Code Violet", "content_version": "01.000.028", "resolution": "3840x2160", "window": {"spec": "seconds 240:30", "first_present": 156, "ms": 30640.15}, "presents": 10, "frame_ms": {"p50": 3992.296, "p90": 5427.294, "p99": 5427.294, "max": 5427.294}, "gpu_busy_ms_per_present": 744.568, "worker_busy_pct": {"queue worker 0x0": 99.936, "queue worker 0x20": 98.571}, "top_phases_ms_per_frame": {"Driver.Packet": 6081.167, "Driver.Packet.dispatch": 3315.598, "Driver.Dispatch": 3314.242, "Vulkan.Dispatch": 2437.039, "Vulkan.Dispatch.shader_resources": 2427.172, "Resources.Complete": 2421.096, "Driver.Packet.memory_wait": 1878.356, "GpuMutex.wait.hook": 1015.725}, "trace_dropped": false, "trace": "aps5-trace-ddeeddfff4ca-2886059.json.gz"} {"commit": "6208617c95f1", "dirty": false, "env": {"APS5_PAD_INPUT_FILE": "<path>", "APS5_TRACE_EVENTS": "4194304", "APS5_TRACE_SECONDS": "240:30"}, "gpu": "AMD Radeon RX 6650 XT (RADV NAVI23)", "driver": "radv Mesa 26.2.4-arch1.1", "os": "Linux 7.2.9-arch1-1", "cpu": "AMD Ryzen 9 7950X 16-Core Processor", "cpu_threads": 32, "memory_mib": 127901, "title_id": "PPSA26528", "title": "Code Violet", "content_version": "01.000.028", "resolution": "3840x2160", "window": {"spec": "seconds 240:30", "first_present": 181, "ms": 30888.713}, "presents": 15, "frame_ms": {"p50": 1757.209, "p90": 2984.839, "p99": 3937.0, "max": 3937.0}, "gpu_busy_ms_per_present": 682.819, "worker_busy_pct": {"queue worker 0x0": 99.922, "queue worker 0x20": 99.501}, "top_phases_ms_per_frame": {"Driver.Packet": 4106.071, "Driver.Packet.dispatch": 2124.983, "Driver.Dispatch": 2121.846, "Vulkan.Dispatch": 1540.429, "Vulkan.Dispatch.shader_resources": 1532.391, "Resources.Complete": 1529.579, "Driver.Packet.memory_wait": 1302.325, "GpuMutex.wait.hook": 654.578}, "trace_dropped": false, "trace": "aps5-trace-6208617c95f1-3013032.json.gz"} {"commit": "6208617c95f1", "dirty": false, "env": {"APS5_PAD_INPUT_FILE": "<path>", "APS5_TRACE_EVENTS": "4194304", "APS5_TRACE_SECONDS": "240:30"}, "gpu": "AMD Radeon RX 6650 XT (RADV NAVI23)", "driver": "radv Mesa 26.2.4-arch1.1", "os": "Linux 7.2.9-arch1-1", "cpu": "AMD Ryzen 9 7950X 16-Core Processor", "cpu_threads": 32, "memory_mib": 127901, "title_id": "PPSA26528", "title": "Code Violet", "content_version": "01.000.028", "resolution": "3840x2160", "window": {"spec": "seconds 240:30", "first_present": 186, "ms": 31288.173}, "presents": 17, "frame_ms": {"p50": 1900.036, "p90": 2236.123, "p99": 2340.754, "max": 2340.754}, "gpu_busy_ms_per_present": 674.571, "worker_busy_pct": {"queue worker 0x0": 99.905, "queue worker 0x20": 98.584}, "top_phases_ms_per_frame": {"Driver.Packet": 3651.607, "Driver.Packet.dispatch": 1825.097, "Driver.Dispatch": 1824.09, "Vulkan.Dispatch": 1312.238, "Vulkan.Dispatch.shader_resources": 1303.662, "Resources.Complete": 1286.777, "Driver.Packet.memory_wait": 1254.13, "GpuMutex.wait.hook": 680.343}, "trace_dropped": false, "trace": "aps5-trace-6208617c95f1-3133785.json.gz"} {"commit": "ddeeddfff4ca", "dirty": false, "env": {"APS5_PAD_INPUT_FILE": "<path>", "APS5_TRACE_EVENTS": "4194304", "APS5_TRACE_SECONDS": "240:30"}, "gpu": "AMD Radeon RX 6650 XT (RADV NAVI23)", "driver": "radv Mesa 26.2.4-arch1.1", "os": "Linux 7.2.9-arch1-1", "cpu": "AMD Ryzen 9 7950X 16-Core Processor", "cpu_threads": 32, "memory_mib": 127901, "title_id": "PPSA26528", "title": "Code Violet", "content_version": "01.000.028", "resolution": "3840x2160", "window": {"spec": "seconds 240:30", "first_present": 161, "ms": 34131.142}, "presents": 11, "frame_ms": {"p50": 2962.007, "p90": 4727.645, "p99": 5025.638, "max": 5025.638}, "gpu_busy_ms_per_present": 656.36, "worker_busy_pct": {"queue worker 0x0": 99.943, "queue worker 0x20": 99.06}, "top_phases_ms_per_frame": {"Driver.Packet": 6174.132, "Driver.Packet.dispatch": 3751.391, "Driver.Dispatch": 3750.419, "Vulkan.Dispatch": 2526.365, "Vulkan.Dispatch.shader_resources": 2517.92, "Resources.Complete": 2509.58, "Driver.Packet.memory_wait": 1551.969, "GpuMutex.wait.dispatch": 997.572}, "trace_dropped": false, "trace": "aps5-trace-ddeeddfff4ca-3247948.json.gz"} {"commit": "6208617c95f1", "dirty": false, "env": {"APS5_PAD_INPUT_FILE": "<path>", "APS5_TRACE_EVENTS": "4194304", "APS5_TRACE_SECONDS": "240:30"}, "gpu": "AMD Radeon RX 6650 XT (RADV NAVI23)", "driver": "radv Mesa 26.2.4-arch1.1", "os": "Linux 7.2.9-arch1-1", "cpu": "AMD Ryzen 9 7950X 16-Core Processor", "cpu_threads": 32, "memory_mib": 127901, "title_id": "PPSA26528", "title": "Code Violet", "content_version": "01.000.028", "resolution": "3840x2160", "window": {"spec": "seconds 240:30", "first_present": 179, "ms": 30629.534}, "presents": 12, "frame_ms": {"p50": 2407.655, "p90": 3490.165, "p99": 4600.331, "max": 4600.331}, "gpu_busy_ms_per_present": 684.304, "worker_busy_pct": {"queue worker 0x0": 99.934, "queue worker 0x20": 99.217}, "top_phases_ms_per_frame": {"Driver.Packet": 5081.035, "Driver.Packet.dispatch": 2921.691, "Driver.Dispatch": 2920.738, "Vulkan.Dispatch": 2002.647, "Vulkan.Dispatch.shader_resources": 1994.514, "Resources.Complete": 1988.964, "Driver.Packet.memory_wait": 1505.24, "GpuMutex.wait.hook": 722.85}, "trace_dropped": false, "trace": "aps5-trace-6208617c95f1-3364695.json.gz"} {"commit": "ddeeddfff4ca", "dirty": false, "env": {"APS5_PAD_INPUT_FILE": "<path>", "APS5_TRACE_EVENTS": "4194304", "APS5_TRACE_SECONDS": "240:30"}, "gpu": "AMD Radeon RX 6650 XT (RADV NAVI23)", "driver": "radv Mesa 26.2.4-arch1.1", "os": "Linux 7.2.9-arch1-1", "cpu": "AMD Ryzen 9 7950X 16-Core Processor", "cpu_threads": 32, "memory_mib": 127901, "title_id": "PPSA26528", "title": "Code Violet", "content_version": "01.000.028", "resolution": "3840x2160", "window": {"spec": "seconds 240:30", "first_present": 154, "ms": 31370.837}, "presents": 12, "frame_ms": {"p50": 3309.874, "p90": 4205.095, "p99": 4248.044, "max": 4248.044}, "gpu_busy_ms_per_present": 631.648, "worker_busy_pct": {"queue worker 0x0": 99.935, "queue worker 0x20": 98.603}, "top_phases_ms_per_frame": {"Driver.Packet": 5189.17, "Driver.Packet.dispatch": 3007.904, "Driver.Dispatch": 3006.72, "Vulkan.Dispatch": 2084.577, "Vulkan.Dispatch.shader_resources": 2075.89, "Resources.Complete": 2042.26, "Driver.Packet.memory_wait": 1379.514, "GpuMutex.wait.hook": 804.84}, "trace_dropped": false, "trace": "aps5-trace-ddeeddfff4ca-3481320.json.gz"} {"commit": "ddeeddfff4ca", "dirty": false, "env": {"APS5_PAD_INPUT_FILE": "<path>", "APS5_TRACE_EVENTS": "4194304", "APS5_TRACE_SECONDS": "240:30"}, "gpu": "AMD Radeon RX 6650 XT (RADV NAVI23)", "driver": "radv Mesa 26.2.4-arch1.1", "os": "Linux 7.2.9-arch1-1", "cpu": "AMD Ryzen 9 7950X 16-Core Processor", "cpu_threads": 32, "memory_mib": 127901, "title_id": "PPSA26528", "title": "Code Violet", "content_version": "01.000.028", "resolution": "3840x2160", "window": {"spec": "seconds 240:30", "first_present": 159, "ms": 30481.98}, "presents": 11, "frame_ms": {"p50": 2036.421, "p90": 4246.281, "p99": 4663.05, "max": 4663.05}, "gpu_busy_ms_per_present": 810.726, "worker_busy_pct": {"queue worker 0x0": 99.94, "queue worker 0x20": 98.922}, "top_phases_ms_per_frame": {"Driver.Packet": 5510.018, "Driver.Packet.dispatch": 3208.028, "Driver.Dispatch": 3206.827, "Vulkan.Dispatch": 2244.751, "Vulkan.Dispatch.shader_resources": 2236.138, "Resources.Complete": 2217.781, "Driver.Packet.memory_wait": 1452.236, "GpuMutex.wait.hook": 829.56}, "trace_dropped": false, "trace": "aps5-trace-ddeeddfff4ca-3599341.json.gz"} {"commit": "6208617c95f1", "dirty": false, "env": {"APS5_PAD_INPUT_FILE": "<path>", "APS5_TRACE_EVENTS": "4194304", "APS5_TRACE_SECONDS": "240:30"}, "gpu": "AMD Radeon RX 6650 XT (RADV NAVI23)", "driver": "radv Mesa 26.2.4-arch1.1", "os": "Linux 7.2.9-arch1-1", "cpu": "AMD Ryzen 9 7950X 16-Core Processor", "cpu_threads": 32, "memory_mib": 127901, "title_id": "PPSA26528", "title": "Code Violet", "content_version": "01.000.028", "resolution": "3840x2160", "window": {"spec": "seconds 240:30", "first_present": 178, "ms": 32057.776}, "presents": 15, "frame_ms": {"p50": 2021.931, "p90": 2604.798, "p99": 4700.152, "max": 4700.152}, "gpu_busy_ms_per_present": 718.208, "worker_busy_pct": {"queue worker 0x0": 99.923, "queue worker 0x20": 98.767}, "top_phases_ms_per_frame": {"Driver.Packet": 4245.321, "Driver.Packet.dispatch": 2323.912, "Driver.Dispatch": 2322.844, "Vulkan.Dispatch": 1614.889, "Vulkan.Dispatch.shader_resources": 1607.154, "Resources.Complete": 1582.581, "Driver.Packet.memory_wait": 1307.953, "GpuMutex.wait.hook": 696.814}, "trace_dropped": false, "trace": "aps5-trace-6208617c95f1-3716801.json.gz"} ``` - Earlier observations, kept for the record (not controlled evidence): - Base `main` 9f4ddf7cf9; this branch has the change `cc53b45601` and a test commit `317d528af7`. - New `agc_reference_storage` (CPU): empty store, reuse of the same allocation, smallest fit, eviction of the oldest by byte limit and by slot count (checked against the identities of the retained buffers), oversize storage, and `Return`/eviction/`Take` with the allocation-failure countdown armed (still armed afterwards, byte count consistent). A store whose eviction allocates terminates the test with `std::bad_alloc`. - `ctest -R 'heap_mirror|sparse_heap|reference_storage|bda|guest_memory_lifetime|sparse' -V` on `main` and on this PR, same machine and GPU, `ANYPS5_REQUIRE_VULKAN=1`, `ANYPS5_NO_SHADER_CACHE=1`, `VK_INSTANCE_LAYERS=VK_LAYER_KHRONOS_validation` (layer 1.4.363 loaded; neither log reports `was not found but was requested`): main (9f4ddf7cf9) 28/29, PR (`cc53b45601`) 29/30 (the extra test is the new one). Both fail `agc_driver_guest_memory_lifetime` the same way (`radv/amdgpu: The CS has been rejected (-14)`, `guest prefix unmap failed`), and both logs hold the same validation errors: 2 × `VUID-vkCmdCopyBuffer-srcBuffer-00118`, 2 × `VUID-vkResetFences-pFences-01123`. No new `VUID-`. - **Diagnostic observations, not controlled performance evidence.** Integration build, not unmodified main: Echoes of the End PPSA25636 01.012.000 stops after about 30 s on main, so both sides are main 33a6d6bbfb + #8089 + #8762 + #8091 + #4449, without and with this commit. Unattended start to the loading screen, no input, one runtime directory for every run: the shader and pipeline cache directory is shared, so initial cache contents are not matched between runs, and no speedup is claimed from these lines. Ryzen 9 7950X, RX 6650 XT, RADV Mesa 26.2.4, Linux 7.2.9. Order base, PR, PR, base: Before (integration `8a251ef745`): **seconds 40:60** from present 340: 11 presents, frame p50 5867.4 / p90 7221.6 / p99 7377.7 / max 7377.7 ms, GPU busy 543.2 ms per present **seconds 40:60** from present 351: 11 presents, frame p50 5427.9 / p90 6189.5 / p99 7141.4 / max 7141.4 ms, GPU busy 497.8 ms per present After (integration + this PR, `6e0a219cbe`): **seconds 40:60** from present 343: 15 presents, frame p50 4069.4 / p90 5171.4 / p99 5460.5 / max 5460.5 ms, GPU busy 497.8 ms per present **seconds 40:60** from present 348: 16 presents, frame p50 4004.1 / p90 4933.0 / p99 5394.2 / max 5394.2 ms, GPU busy 479.7 ms per present The title still loads at well under 1 FPS on both sides. The captures ran on an integration with the earlier base `33a6d6bbfb`; the PR commit was cherry-picked onto it (`6e0a219cbe`). Traces, logs, screenshots, profiles and validation logs: [evidence archive](https://github.com/JJenkx/AnyPS5/releases/download/game-library-checks-20261016/echoes-heap-reference-reuse-cc53b456-20261021.tar.gz) (SHA-256 `00bbfd328cc0ecbed29aedd3925217dc6e39a9a018170bd941549b5146af27be`). - Second title, **neutral observation, no improvement claimed**: Mortal Shell II PPSA34008, measured by another worker on the same machine and scene, `APS5_TRACE_SECONDS=150:30`, one run each, separate relinked runtimes, initial shader/pipeline cache state not reported as matched. Base main `e0e57a3270` + #8839 (`641fce5c84`), change = base + this PR (`91d0f400ba`): Before: **seconds 150:30** from present 26: 6 presents, frame p50 4885.1 / p90 7341.3 / p99 7341.3 / max 7341.3 ms, GPU busy 186.3 ms per present After: **seconds 150:30** from present 40: 6 presents, frame p50 5074.1 / p90 5685.3 / p99 5685.3 / max 5685.3 ms, GPU busy 178.7 ms per present `Resources.Complete` 5.29 vs 5.14 ms per dispatch: no measurable change in that title, where the per-dispatch cost is the copy and the `WriteChanged` compare that this PR keeps. [Traces](https://github.com/JJenkx/AnyPS5/releases/download/game-library-checks-20261016/mortal-shell-2-PPSA34008-8874-traces-20261021.tar.gz) (SHA-256 `4412bd6c74fc8493e765d3d33b970a6b947ef900e09e6a38384d0ebc4f659c25`). - Review: `agc_heap_mirror_reference_size` (317d528af7) checks a smaller reference written back after a larger one reused its storage; with `takeHeapReferences` keeping the storage's capacity as its size it fails with `heap mirror write-back has no reference`. - `python3 tools/check_conventions.py --base origin/main` passes. The overlap tool reports #8016 and #7647, which rewrite the same reference construction for device-local and resident heap mirrors; they do not reuse storage, and whichever lands later rebases onto the other. <!-- codex-maintenance-20261031-repeat4-qualification-8874 --> **Supplemental exact-head qualification — 2026-10-31** Merged main `602c0e417ca11f53de54ffe7b3253e95cb93c0d4` into previous head `0ae75877c9cb6238c59a6894f527cfe3221b42ee`, retaining the complete original history. New public head: `e21b872338378862bd71db9b3d22de26b8a7dcea`. The sole conflict was adjacent includes in `Recorder.cpp`; both main's `DepthSurface.hpp` and this PR's `ReferenceStorage.hpp` remain. The topic's added/removed lines are identical to its patch against `08a10d225306`; main's newer behavior, fixtures, debt and submodule pins remain. Conventions and whitespace checks pass. Fresh main `85cdddc1b0e89fe66744f437513ccfdcb16f72f6` changes no AGC/shader paths after the tested pin, and its merge preview is clean. Paired focused gate, Release with SPIRV-Tools ON, AMD Radeon RX 6650 XT / RADV Mesa 26.2.6, Linux 7.2.11-arch1-1. Same selected groups as the earlier focused gate; one execution per group: | Arm | Result | Actual Khronos layer insertions | VUIDs | Skips | |---|---|---|---|---| | main `602c0e417ca` | 16/16 passed | 4 | 0 | 0 | | change `e21b8723383` | 18/18 passed | 4 | 0 | 0 | The change adds `agc_reference_storage` and `agc_heap_mirror_reference_size`. Both arms used `ANYPS5_REQUIRE_VULKAN=1`, `ANYPS5_NO_SHADER_CACHE=1`, `VK_INSTANCE_LAYERS=VK_LAYER_KHRONOS_validation` and verbose CTest. Neither log reports the requested layer missing. The physical groups are `agc_host_import_unmap`, `agc_host_import_retirement`, `agc_sparse_run_import` and `agc_sparse_run_import_copied`; the remaining groups use CPU/mock Vulkan. The complete build/test harnesses ran through FIFO tickets1925/1926 under the explicitly title-free infrastructure reservation PPSA00004, now released. Qualification detail: both CTest commands exited0 and their JUnit files report every selected group passed. The wrapper then exited1 because its postprocessor incorrectly required physical-layer insertion in CPU/mock `agc_driver_graphics`. The original failed wrapper receipts are retained. A separate audit (`audit-raw.py`, `paired-raw-audit.json`) validates the unchanged raw logs/JUnit against the actual four physical groups; no source or test behavior was changed, and no rerun is claimed. This maintenance adds no title capture or performance/RSS claim. The earlier matched capture remains inconclusive ([comment6524722530](https://github.com/boykopovar/AnyPS5/pull/8874#issuecomment-6524722530)). Existing external NVIDIA/Windows and older AMD evidence remains tied to its original pins and scope. Evidence: [immutable source and paired GPU receipts](https://github.com/JJenkx/AnyPS5/releases/download/linux-validation-20261023/pr8874-e21b8723-main602c0e41-focused-vvl-20261031-final.tar.gz) (SHA-256 `5d3548a127cb5d60199c18cff61e1d7df947fa5923d79a73f33dc116311f01e3`, download verified). AI-assisted: yes. <!-- codex-maintenance-20261101-graphics-8874 --> ### Supplemental qualification (2026-11-01) Merged current main `93dbd0f82aea684e95f15f06e7d42c0064af18cf` into previous head `e21b872338378862bd71db9b3d22de26b8a7dcea`. New public head: `de5afa814417a3123cb5f5388ae982bda52477ce`. The conflicts were main's AGC CMake test split, the heap-mirror sweep signature and adjacent debt entries. Kept main's `sweepMirrors(neededBytes, protectAddress)` behavior and the PR's `ReferenceStorage::Shared().ReleaseIdle()` poll; moved the PR's target/test registrations into the corresponding new CMake fragments. Kept main's updated host-import budget entry and this PR's storage-limit debt. All nonblank topic added/removed lines are identical to the previous topic patch; complete original history and main's gitlinks are retained. Conventions and whitespace pass. Paired focused Release gates, SPIRV-Tools ON, AMD Radeon RX 6650 XT / RADV Mesa26.2.6, Linux7.2.11-arch1-1, one execution per group: | Arm | Focused groups | Actual Khronos insertions | VUIDs | Skips | |---|---|---|---|---| | main `93dbd0f82aea` | 16/16 pass | 4 | 0 | 0 | | PR `de5afa814417` | 18/18 pass | 4 | 0 | 0 | Both ran verbose CTest with `ANYPS5_REQUIRE_VULKAN=1 ANYPS5_NO_SHADER_CACHE=1 VK_INSTANCE_LAYERS=VK_LAYER_KHRONOS_validation`, and neither reports the requested layer missing. Four host-import/sparse-run groups execute on the physical GPU; the other groups use CPU/mock Vulkan. The PR adds the reference-storage and reference-size regressions. Whole isolated build/test harnesses ran through the title-free PPSA00004 infrastructure reservation/FIFO (main2487, change2489), with service-owned PTYs; both wrappers and CTest exited0. A prior candidate ticket2486 was cancelled while queued, before execution, to remove a blank EOF in the new fragment; that receipt is retained. No new title capture, FPS, allocation or RSS claim. The previously matched title capture remains inconclusive (comment6524722530); historical Windows/NVIDIA/AMD reports retain their own pins/scopes. Evidence: [frozen source and qualification receipts](https://github.com/JJenkx/AnyPS5/releases/download/linux-validation-20261023/pr8874-de5afa81-main93db-focused-vvl-20261101-final.tar.gz) (SHA-256 `44a57b5d68d03b34fa53d61a4e20e2c54316d4ff607c86c66e0f99cf14723ae8`, downloaded bytes and internal manifest verified). AI-assisted: yes. ### Checklist <!-- Rules behind each item: https://github.com/boykopovar/AnyPS5/blob/main/CONTRIBUTING.md --> - [x] Based on current `main`; no other open PR implements the same functions - [x] One topic per PR; follow-ups go in a new PR - [x] No comments in code except [technical debt](https://github.com/boykopovar/AnyPS5/blob/main/docs/dev/CONVENTIONS.md) - [x] Unimplemented paths throw (`NotImplemented_nid_no_patch`); silent stubs are listed under Silent stubs in their library's [technical debt](https://github.com/boykopovar/AnyPS5/tree/main/docs/dev/debt) file - [x] No notes, investigation `.md` files or images added to the repository (attach them to this PR) - [x] New third-party code is a submodule built from source - [x] Generic behaviour, not specific to one title - [x] Depends on: none - [x] Fixes: none - [x] Unblocks: none - [x] GPUs tested: AMD Radeon RX 6650 XT, RADV Mesa 26.2.4, Arch Linux 7.2.9-arch1-1; AMD Radeon RX 6700 XT, Windows 11 Enterprise 10.0.22621, AMD 32.0.21045.16010; NVIDIA RTX 2000 Ada Generation, driver 595.99.02, Ubuntu 26.04.1 LTS (external exact-head report below).; AMD Radeon RX 6650 XT, RADV Mesa 26.2.6, Linux 7.2.11-arch1-1 (current paired focused tests) - [x] AI-assisted: yes <!-- codex-contributor-note-20261027-pr8874 --> Contributor-reported attribution observation: @milescoviello measured Borderlands 4 PPSA01494 on RTX 4070 Ti / NVIDIA 615.71.09, Linux, warm shader cache, 600 s, with local phase counters. Their candidate is main `cbee224804` plus this head `f7aec2a966` **and #9858**, so this is a mixed integration. The after-region upload phase averaged about 71 ms on control versus 27 ms on candidate; total slow-upload counts and other phase costs differed. This supports investigating heap-reference/flush cost, but single runs with an extra PR do not isolate this PR's frame-time effect or establish an FPS gain. No new local title run is claimed. [Original report and full limits](https://github.com/boykopovar/AnyPS5/pull/8874#issuecomment-6422320806). ### External NVIDIA validation (2026-10-30) [TechLevelZero’s report](https://github.com/boykopovar/AnyPS5/pull/8874#issuecomment-6523579972) tested exact head `0ae75877c9cb6238c59a6894f527cfe3221b42ee` merged onto main `98ddd9c`: Release with SPIRV-Tools enabled built successfully; 2,367 tests passed, four failed (all already failing or unstable on main), and 41 skipped, from 2,412 selected. The report records 905 GPU tests with no new validation IDs; four existing IDs remain. `agc_heap_mirror_reference_size` and `agc_reference_storage` were validated without a matching main validation pass, and the job-manager capacity test needed a retry. This is attributed external evidence, not a new local run. Hardware: NVIDIA RTX 2000 Ada Generation, driver 595.99.02, Vulkan 1.4.329; Ubuntu 26.04.1 LTS, kernel 7.0.0-38-generic, Ubuntu 24.04 container.
github-actions[bot] commented 2026-10-21 03:55:25 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by github-actions[bot] on 2026-10-21T03:55:25Z.


This pull request is labeled perf, so it needs the summary line of a capture on main and one with the change, from the same title, scene and machine, as the Performance report form asks. Please paste both aps5-summary.jsonl lines, attach the two traces and add the output of tools/trace_digest.py.

<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6307642090 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/8874#issuecomment-6307642090). Originally posted by [github-actions[bot]](https://github.com/apps/github-actions) on 2026-10-21T03:55:25Z. --- <!-- pr-labels-perf --> This pull request is labeled `perf`, so it needs the summary line of a capture on `main` and one with the change, from the same title, scene and machine, as the Performance report form asks. Please paste both `aps5-summary.jsonl` lines, attach the two traces and add the output of `tools/trace_digest.py`.
MarcZX10 commented 2026-10-21 04:11:36 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-10-21T04:11:36Z.

Code review location: core/libs/prx/libSceAgcDriver/Graphics/src/GuestBufferMemory.cpp; line 5351

@@ -5341,7 +5348,9 @@ void GuestBufferMemory::takeHeapReferences() {
         const auto served = std::min(end, servedEnd(*found));
         if (begin >= served) continue;
         const auto bytes = mirror.buffer->Bytes().subspan(static_cast<std::size_t>(begin - mirror.base), static_cast<std::size_t>(served - begin));
-        heapReferences.emplace_back(begin, std::vector<std::byte>(bytes.begin(), bytes.end()));
+        auto storage = ReferenceStorage::Shared().Take(bytes.size());

When Take() reuses a previously larger vector, assign() updates its contents but does not reduce its size. WriteBack() later requires reference->second.size() == length for each merged heap range, so a smaller subsequent range can hit heap mirror write-back has no reference even though the begin address matches. Could this resize the vector to bytes.size() after ensuring capacity (or resize before copying), and add a regression that returns a larger buffer then takes it for a smaller reference and exercises the size invariant?

<!-- greyfinch-sync:boykopovar/AnyPS5:review-comment:4332954832 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/8874#discussion_r4332954832). Originally posted by [MarcZX10](https://github.com/MarcZX10) on 2026-10-21T04:11:36Z. **Code review location:** `core/libs/prx/libSceAgcDriver/Graphics/src/GuestBufferMemory.cpp`; line 5351 ~~~~diff @@ -5341,7 +5348,9 @@ void GuestBufferMemory::takeHeapReferences() { const auto served = std::min(end, servedEnd(*found)); if (begin >= served) continue; const auto bytes = mirror.buffer->Bytes().subspan(static_cast<std::size_t>(begin - mirror.base), static_cast<std::size_t>(served - begin)); - heapReferences.emplace_back(begin, std::vector<std::byte>(bytes.begin(), bytes.end())); + auto storage = ReferenceStorage::Shared().Take(bytes.size()); ~~~~ --- When `Take()` reuses a previously larger vector, `assign()` updates its contents but does not reduce its size. `WriteBack()` later requires `reference->second.size() == length` for each merged heap range, so a smaller subsequent range can hit `heap mirror write-back has no reference` even though the begin address matches. Could this resize the vector to `bytes.size()` after ensuring capacity (or resize before copying), and add a regression that returns a larger buffer then takes it for a smaller reference and exercises the size invariant?
JJenkx commented 2026-10-21 04:29:52 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by JJenkx on 2026-10-21T04:29:52Z.

Code review location: core/libs/prx/libSceAgcDriver/Graphics/src/GuestBufferMemory.cpp; line 5351

@@ -5341,7 +5348,9 @@ void GuestBufferMemory::takeHeapReferences() {
         const auto served = std::min(end, servedEnd(*found));
         if (begin >= served) continue;
         const auto bytes = mirror.buffer->Bytes().subspan(static_cast<std::size_t>(begin - mirror.base), static_cast<std::size_t>(served - begin));
-        heapReferences.emplace_back(begin, std::vector<std::byte>(bytes.begin(), bytes.end()));
+        auto storage = ReferenceStorage::Shared().Take(bytes.size());

Thanks for checking this. The size does follow the new reference: std::vector::assign(first, last) replaces the whole contents, so size() becomes last - first while the larger capacity is kept ([sequence.reqmts]). The vector is not resized to its capacity anywhere on this path, so WriteBack's size() == length check holds.

317d528af7 adds checks for it on the production path:

  • agc_heap_mirror_reference_size (--heap-mirror-reference-size, Linux and Windows) makes writable heap-mirror builds of 8 KiB, then 2 KiB, then 8 KiB through AddWritable / Upload / WriteBack, with a GPU store in each, and checks that every store reaches guest memory. The 2 KiB reference takes the 8 KiB storage the first write-back returned.
  • agc_reference_storage gains LargerStorageTakesTheReferenceSize: a smaller assign into larger reused storage keeps the same allocation, has the smaller size and holds the reference's bytes.

Negative control: with takeHeapReferences changed to keep the storage at its capacity (resize(capacity()) plus a copy instead of assign), agc_heap_mirror_reference_size fails with AGC graphics: heap mirror write-back has no reference, which is the failure you describe. With the PR's assign it passes, as do agc_driver_graphics and agc_reference_storage (Linux 7.2.9, GCC, Release).

<!-- greyfinch-sync:boykopovar/AnyPS5:review-comment:4333045811 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/8874#discussion_r4333045811). Originally posted by [JJenkx](https://github.com/JJenkx) on 2026-10-21T04:29:52Z. **Code review location:** `core/libs/prx/libSceAgcDriver/Graphics/src/GuestBufferMemory.cpp`; line 5351 ~~~~diff @@ -5341,7 +5348,9 @@ void GuestBufferMemory::takeHeapReferences() { const auto served = std::min(end, servedEnd(*found)); if (begin >= served) continue; const auto bytes = mirror.buffer->Bytes().subspan(static_cast<std::size_t>(begin - mirror.base), static_cast<std::size_t>(served - begin)); - heapReferences.emplace_back(begin, std::vector<std::byte>(bytes.begin(), bytes.end())); + auto storage = ReferenceStorage::Shared().Take(bytes.size()); ~~~~ --- Thanks for checking this. The size does follow the new reference: `std::vector::assign(first, last)` replaces the whole contents, so `size()` becomes `last - first` while the larger capacity is kept ([sequence.reqmts]). The vector is not resized to its capacity anywhere on this path, so `WriteBack`'s `size() == length` check holds. 317d528af7 adds checks for it on the production path: - `agc_heap_mirror_reference_size` (`--heap-mirror-reference-size`, Linux and Windows) makes writable heap-mirror builds of 8 KiB, then 2 KiB, then 8 KiB through `AddWritable` / `Upload` / `WriteBack`, with a GPU store in each, and checks that every store reaches guest memory. The 2 KiB reference takes the 8 KiB storage the first write-back returned. - `agc_reference_storage` gains `LargerStorageTakesTheReferenceSize`: a smaller `assign` into larger reused storage keeps the same allocation, has the smaller size and holds the reference's bytes. Negative control: with `takeHeapReferences` changed to keep the storage at its capacity (`resize(capacity())` plus a copy instead of `assign`), `agc_heap_mirror_reference_size` fails with `AGC graphics: heap mirror write-back has no reference`, which is the failure you describe. With the PR's `assign` it passes, as do `agc_driver_graphics` and `agc_reference_storage` (Linux 7.2.9, GCC, Release).
JJenkx commented 2026-10-21 21:45:18 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by JJenkx on 2026-10-21T21:45:18Z.


A matched-seed capture pair on a real title. It does not show a measurable gain from this change, so the PR stays in draft.

Setup

  • Echoes of the End (PPSA25636), Linux 7.2.9, RX 6650 XT, RADV (Mesa 26.2.4).
  • The title needs a few open PRs to reach its scene (#8089, #4449, #8091, #8908 and others), so this is not plain main. Both arms use the same tree:
    • without: e68bd0891a, this change and its follow-up reverted;
    • with: 9f2beb563a, the same tree plus this change only. The two differ only by this PR's files (281 lines).
  • Both arms use the same shader cache, Mesa cache and save state, restored from one seed before each run.
  • Same build directory, rebuilt incrementally between arms. No environment overrides.
  • 420 s per run, with APS5_TRACE_SECONDS=290:120.

Summary lines

  • without: seconds 290:120 from present 461: 88 presents, frame p50 1112.6 / p90 2018.2 / p99 4388.6 / max 4388.6 ms, GPU busy 635.5 ms per present
  • with: seconds 290:120 from present 442: 90 presents, frame p50 1042.2 / p90 2157.3 / p99 5609.5 / max 5609.5 ms, GPU busy 453.3 ms per present

tools/performance_compare.py, candidate minus baseline:

  • mean frame -3.1 %, p50 -6.3 %, p90 +6.9 %, p99 +27.8 %;
  • Driver.Dispatch +0.1 %, Driver.Packet -3.6 %.

Reading

  • The windows start at different presents (461 and 442), and one pair has no repeat, so these differences are within run-to-run variance.
  • The GPU busy drop is not attributable to a change in CPU-side reference buffers.
  • This title's frame time is dominated by GPU-side storage image churn and by CPU copies of a large sparse buffer, not by the allocations this PR removes.
  • Both captures report dropped trace events.

So: no regression and no demonstrated improvement on this title. The PR needs a capture from a title where heap-mirror reference allocation shows up in the profile before it can leave draft.

<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6327244751 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/8874#issuecomment-6327244751). Originally posted by [JJenkx](https://github.com/JJenkx) on 2026-10-21T21:45:18Z. --- A matched-seed capture pair on a real title. It does not show a measurable gain from this change, so the PR stays in draft. **Setup** - Echoes of the End (PPSA25636), Linux 7.2.9, RX 6650 XT, RADV (Mesa 26.2.4). - The title needs a few open PRs to reach its scene (#8089, #4449, #8091, #8908 and others), so this is not plain `main`. Both arms use the same tree: - without: `e68bd0891a`, this change and its follow-up reverted; - with: `9f2beb563a`, the same tree plus this change only. The two differ only by this PR's files (281 lines). - Both arms use the same shader cache, Mesa cache and save state, restored from one seed before each run. - Same build directory, rebuilt incrementally between arms. No environment overrides. - 420 s per run, with `APS5_TRACE_SECONDS=290:120`. **Summary lines** - without: `seconds 290:120 from present 461: 88 presents, frame p50 1112.6 / p90 2018.2 / p99 4388.6 / max 4388.6 ms, GPU busy 635.5 ms per present` - with: `seconds 290:120 from present 442: 90 presents, frame p50 1042.2 / p90 2157.3 / p99 5609.5 / max 5609.5 ms, GPU busy 453.3 ms per present` `tools/performance_compare.py`, candidate minus baseline: - mean frame -3.1 %, p50 -6.3 %, p90 +6.9 %, p99 +27.8 %; - `Driver.Dispatch` +0.1 %, `Driver.Packet` -3.6 %. **Reading** - The windows start at different presents (461 and 442), and one pair has no repeat, so these differences are within run-to-run variance. - The GPU busy drop is not attributable to a change in CPU-side reference buffers. - This title's frame time is dominated by GPU-side storage image churn and by CPU copies of a large sparse buffer, not by the allocations this PR removes. - Both captures report dropped trace events. So: no regression and no demonstrated improvement on this title. The PR needs a capture from a title where heap-mirror reference allocation shows up in the profile before it can leave draft.
adriadam10 commented 2026-10-23 18:55:15 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by adriadam10 on 2026-10-23T18:55:15Z.

Review: CHANGES_REQUESTED


Thanks for the measurements; the reuse itself reads correct (Take/Return don't allocate, the reference keeps its own size, the new tests pin that). One blocker:

  • core/libs/prx/libSceAgcDriver/Graphics/src/ReferenceStorage.cpp:62: Shared() is a process-lifetime store that keeps up to 8 buffers / 2 GiB idle on every driver and GPU, and nothing frees it other than newer Return calls evicting older ones. After a heavy scene ends, up to 2 GiB of RSS stays resident indefinitely. The PR body gives the bound but not what releases it, and there is no peak/steady RSS before/after. Please add:
    • peak and steady-state RSS on main vs this PR for the same scene (the Code Violet runs you already have are enough; /proc/<pid>/status VmHWM/VmRSS sampled in both arms);
    • a release path (e.g. drop the idle buffers when no GuestBufferMemory holds references / after a period without a take, or at device teardown), or a justification for 2 GiB based on those numbers. If the cap is only needed for the largest scenes, a smaller default may keep most of the gain.

Once that is in, the rest looks good to me.

<!-- greyfinch-sync:boykopovar/AnyPS5:review:5633104902 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/8874#pullrequestreview-5633104902). Originally posted by [adriadam10](https://github.com/adriadam10) on 2026-10-23T18:55:15Z. **Review:** CHANGES_REQUESTED --- Thanks for the measurements; the reuse itself reads correct (`Take`/`Return` don't allocate, the reference keeps its own size, the new tests pin that). One blocker: - `core/libs/prx/libSceAgcDriver/Graphics/src/ReferenceStorage.cpp:62`: `Shared()` is a process-lifetime store that keeps up to 8 buffers / 2 GiB idle on every driver and GPU, and nothing frees it other than newer `Return` calls evicting older ones. After a heavy scene ends, up to 2 GiB of RSS stays resident indefinitely. The PR body gives the bound but not what releases it, and there is no peak/steady RSS before/after. Please add: - peak and steady-state RSS on `main` vs this PR for the same scene (the Code Violet runs you already have are enough; `/proc/<pid>/status` VmHWM/VmRSS sampled in both arms); - a release path (e.g. drop the idle buffers when no `GuestBufferMemory` holds references / after a period without a take, or at device teardown), or a justification for 2 GiB based on those numbers. If the cap is only needed for the largest scenes, a smaller default may keep most of the gain. Once that is in, the rest looks good to me.
MarcZX10 commented 2026-10-29 11:16:27 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-10-29T11:16:27Z.

Review: CHANGES_REQUESTED


Re-checked — changes requested

The latest Linux qualification is detailed and the new NVIDIA run reports 2,277 passed, zero new failures and no new validation IDs. However, both were built against older main snapshots (2227f136 in the author report and 52c09d5 in NVIDIA CI). Current main is ba5b5330b3, and its intervening changes touch this PR's GuestBufferMemory.cpp, Graphics.cpp and CMake registration. Please integrate current main and rerun the focused main/change suites and paired validation comparison on that merge tree.

This PR remains labeled perf. Its latest report explicitly says it has no new title, RSS or speed measurement, while the historical captures are pinned to earlier source/main revisions. Since current main changed the production path being optimized, please refresh the required same-title, same-scene main/change capture pair (or provide a current allocation/RSS measurement that directly validates the stated reuse benefit, with the required performance report artifacts). The current-head CI pass is useful but does not establish either point.''

<!-- greyfinch-sync:boykopovar/AnyPS5:review:5696802381 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/8874#pullrequestreview-5696802381). Originally posted by [MarcZX10](https://github.com/MarcZX10) on 2026-10-29T11:16:27Z. **Review:** CHANGES_REQUESTED --- ## Re-checked — changes requested The latest Linux qualification is detailed and the new NVIDIA run reports 2,277 passed, zero new failures and no new validation IDs. However, both were built against older main snapshots (`2227f136` in the author report and `52c09d5` in NVIDIA CI). Current `main` is `ba5b5330b3`, and its intervening changes touch this PR's `GuestBufferMemory.cpp`, `Graphics.cpp` and CMake registration. Please integrate current main and rerun the focused main/change suites and paired validation comparison on that merge tree. This PR remains labeled `perf`. Its latest report explicitly says it has no new title, RSS or speed measurement, while the historical captures are pinned to earlier source/main revisions. Since current main changed the production path being optimized, please refresh the required same-title, same-scene `main`/change capture pair (or provide a current allocation/RSS measurement that directly validates the stated reuse benefit, with the required performance report artifacts). The current-head CI pass is useful but does not establish either point.''
MarcZX10 commented 2026-10-29 11:16:33 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-10-29T11:16:33Z.

Review: CHANGES_REQUESTED


Re-checked — changes requested

The latest Linux qualification is detailed and the new NVIDIA run reports 2,277 passed, zero new failures and no new validation IDs. However, both were built against older main snapshots (2227f136 in the author report and 52c09d5 in NVIDIA CI). Current main is ba5b5330b3, and its intervening changes touch this PR's GuestBufferMemory.cpp, Graphics.cpp and CMake registration. Please integrate current main and rerun the focused main/change suites and paired validation comparison on that merge tree.

This PR remains labeled perf. Its latest report explicitly says it has no new title, RSS or speed measurement, while the historical captures are pinned to earlier source/main revisions. Since current main changed the production path being optimized, please refresh the required same-title, same-scene main/change capture pair (or provide a current allocation/RSS measurement that directly validates the stated reuse benefit, with the required performance report artifacts). The current-head CI pass is useful but does not establish either point.

<!-- greyfinch-sync:boykopovar/AnyPS5:review:5696803409 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/8874#pullrequestreview-5696803409). Originally posted by [MarcZX10](https://github.com/MarcZX10) on 2026-10-29T11:16:33Z. **Review:** CHANGES_REQUESTED --- ## Re-checked — changes requested The latest Linux qualification is detailed and the new NVIDIA run reports 2,277 passed, zero new failures and no new validation IDs. However, both were built against older main snapshots (`2227f136` in the author report and `52c09d5` in NVIDIA CI). Current `main` is `ba5b5330b3`, and its intervening changes touch this PR's `GuestBufferMemory.cpp`, `Graphics.cpp` and CMake registration. Please integrate current main and rerun the focused main/change suites and paired validation comparison on that merge tree. This PR remains labeled `perf`. Its latest report explicitly says it has no new title, RSS or speed measurement, while the historical captures are pinned to earlier source/main revisions. Since current main changed the production path being optimized, please refresh the required same-title, same-scene `main`/change capture pair (or provide a current allocation/RSS measurement that directly validates the stated reuse benefit, with the required performance report artifacts). The current-head CI pass is useful but does not establish either point.
MarcZX10 commented 2026-10-29 21:35:06 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-10-29T21:35:06Z.

Review: CHANGES_REQUESTED


Re-checked — new head, changes requested

The current head still lacks a performance report captured against current main, and the latest GPU run uses an older main snapshot.

What I ran

Reviewed head 9f226879bc5e9bd488022746b47dbaf714ec05d5; PR base is 899ae3d1ad32ccea94dc24e66fdc948ce8a88171. I compared it with current main fc9240dbc5dc89a6b17a739703e00d26318c7716; the merge preview is clean. No local build or tests were run.

git merge-tree --write-tree refs/remotes/upstream/main refs/review/pr-8874-head
git diff --check refs/remotes/upstream/main...refs/review/pr-8874-head

Results

Check Result
Merge preview onto current main Clean
Diff whitespace check Passed (no output)
NVIDIA GPU workflow CI report for this head, merged onto bb04a4f, reports 2,312 passed, 6 failures (0 new; 5 also on main and 1 unstable on main), and no new validation IDs
Local build/tests Not run
Unedited local command output
merge-tree: eb5442ba5bc743df10ea471d4a572047a62e721d
diff-check: no output; exit status 0

Findings

Blocking

  • The PR remains labeled perf. The newest author report says it contains no new title, RSS, or speed measurement; the latest GPU workflow is a correctness run, not a matched performance capture. The existing performance evidence therefore does not establish this change's performance against current main.
  • Current main has advanced from the author's focused test base 899ae3d and the GPU workflow base bb04a4f. The current-main diff overlaps this PR in core/libs/prx/libSceAgcDriver/CMakeLists.txt, core/libs/prx/libSceAgcDriver/tests/Graphics.cpp, and docs/dev/debt/libSceAgcDriver.md. The clean merge preview does not update the reported test results or performance evidence to that merged tree.

Non-blocking

  • The focused AMD report on head 9f22687 reports 18/18 tests passing versus 16/16 on its 899ae3d baseline, with zero validation IDs. This is useful test evidence, but it does not cover current main or satisfy the performance report requirement.

Not verified

I did not build locally, rerun the focused tests, or run a performance capture. The AMD focused results and NVIDIA CI results above are contributor/CI-reported, not locally reproduced.

To get this to a good state

Please refresh onto current main, rerun the focused comparison on the resulting exact head, and add the required matched main/change performance captures for the same title, scene, and machine, including both aps5-summary.jsonl lines, traces, and tools/trace_digest.py output. I will re-run the same source checks and review the new exact head.

<!-- greyfinch-sync:boykopovar/AnyPS5:review:5705283717 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/8874#pullrequestreview-5705283717). Originally posted by [MarcZX10](https://github.com/MarcZX10) on 2026-10-29T21:35:06Z. **Review:** CHANGES_REQUESTED --- # Re-checked — new head, changes requested The current head still lacks a performance report captured against current `main`, and the latest GPU run uses an older main snapshot. ## What I ran Reviewed head `9f226879bc5e9bd488022746b47dbaf714ec05d5`; PR base is `899ae3d1ad32ccea94dc24e66fdc948ce8a88171`. I compared it with current `main` `fc9240dbc5dc89a6b17a739703e00d26318c7716`; the merge preview is clean. No local build or tests were run. ```sh git merge-tree --write-tree refs/remotes/upstream/main refs/review/pr-8874-head git diff --check refs/remotes/upstream/main...refs/review/pr-8874-head ``` ## Results | Check | Result | |---|---| | Merge preview onto current `main` | Clean | | Diff whitespace check | Passed (no output) | | NVIDIA GPU workflow | CI report for this head, merged onto `bb04a4f`, reports 2,312 passed, 6 failures (0 new; 5 also on main and 1 unstable on main), and no new validation IDs | | Local build/tests | Not run | <details> <summary>Unedited local command output</summary> ```text merge-tree: eb5442ba5bc743df10ea471d4a572047a62e721d diff-check: no output; exit status 0 ``` </details> ## Findings ### Blocking - The PR remains labeled `perf`. The newest author report says it contains no new title, RSS, or speed measurement; the latest GPU workflow is a correctness run, not a matched performance capture. The existing performance evidence therefore does not establish this change's performance against current `main`. - Current `main` has advanced from the author's focused test base `899ae3d` and the GPU workflow base `bb04a4f`. The current-main diff overlaps this PR in `core/libs/prx/libSceAgcDriver/CMakeLists.txt`, `core/libs/prx/libSceAgcDriver/tests/Graphics.cpp`, and `docs/dev/debt/libSceAgcDriver.md`. The clean merge preview does not update the reported test results or performance evidence to that merged tree. ### Non-blocking - The focused AMD report on head `9f22687` reports 18/18 tests passing versus 16/16 on its `899ae3d` baseline, with zero validation IDs. This is useful test evidence, but it does not cover current `main` or satisfy the performance report requirement. ## Not verified I did not build locally, rerun the focused tests, or run a performance capture. The AMD focused results and NVIDIA CI results above are contributor/CI-reported, not locally reproduced. ## To get this to a good state Please refresh onto current `main`, rerun the focused comparison on the resulting exact head, and add the required matched `main`/change performance captures for the same title, scene, and machine, including both `aps5-summary.jsonl` lines, traces, and `tools/trace_digest.py` output. I will re-run the same source checks and review the new exact head.
MarcZX10 commented 2026-10-30 04:21:54 +00:00 (Migrated from github.com)

Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-10-30T04:21:54Z.

Review: CHANGES_REQUESTED


Re-checked — new head, changes requested

The new integration report adds useful GPU correctness evidence, but it does not yet provide the required performance comparison or validation on the latest main snapshot.

What I ran

Reviewed head 0ae75877c9cb6238c59a6894f527cfe3221b42ee, integrated with main at 08a10d225306ad102b57408e2ef7566bcfb829b2; current main is 5ecef095b61e7a406b279c97896f3a8a6fbd6353. Current-main merge preview is clean (tree 58ac36f0761e2e9bbbfcc4dd56e3858bcb0187b5). Since the integration point, main changed five commits; the only shared changed paths are core/libs/prx/libSceAgcDriver/tests/Graphics.cpp and docs/dev/debt/libSceAgcDriver.md.

git merge-tree --write-tree refs/remotes/upstream/main refs/remotes/upstream/pr-8874
git diff --check refs/remotes/upstream/main...refs/remotes/upstream/pr-8874
git diff --name-only 08a10d225306ad102b57408e2ef7566bcfb829b2..refs/remotes/upstream/main

Results

Check Result
Merge preview Clean
Diff check Passed; no output
Hosted conventions and Windows Passed
Focused AMD tests Author reports 18/18 on this head and 16/16 on main at 08a10d2; not independently run
Performance evidence No new same-title, same-scene, same-machine main/change capture pair is present

Findings

Blocking

  • The PR remains labeled perf, while the new report is a correctness run and supplies no matched performance captures or the required report artifacts. This leaves the stated performance result unverified.
  • The new focused tests use main at 08a10d2. Current main has since changed the shared graphics test file; the reported pair therefore does not cover the latest test tree.

Not verified

I did not run a local build, GPU tests, or a performance capture.

To get this to a good state

Please attach the required matched main/change performance captures for the same title, scene, and machine, including both aps5-summary.jsonl lines, traces, and tools/trace_digest.py output. Please also rerun the focused main/change tests using current main 5ecef09 (or the corresponding exact merge tree). I’ll rerun the same source checks on the new head.

<!-- greyfinch-sync:boykopovar/AnyPS5:review:5708046058 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/pull/8874#pullrequestreview-5708046058). Originally posted by [MarcZX10](https://github.com/MarcZX10) on 2026-10-30T04:21:54Z. **Review:** CHANGES_REQUESTED --- # Re-checked — new head, changes requested The new integration report adds useful GPU correctness evidence, but it does not yet provide the required performance comparison or validation on the latest main snapshot. ## What I ran Reviewed head `0ae75877c9cb6238c59a6894f527cfe3221b42ee`, integrated with `main` at `08a10d225306ad102b57408e2ef7566bcfb829b2`; current main is `5ecef095b61e7a406b279c97896f3a8a6fbd6353`. Current-main merge preview is clean (tree `58ac36f0761e2e9bbbfcc4dd56e3858bcb0187b5`). Since the integration point, main changed five commits; the only shared changed paths are `core/libs/prx/libSceAgcDriver/tests/Graphics.cpp` and `docs/dev/debt/libSceAgcDriver.md`. ```sh git merge-tree --write-tree refs/remotes/upstream/main refs/remotes/upstream/pr-8874 git diff --check refs/remotes/upstream/main...refs/remotes/upstream/pr-8874 git diff --name-only 08a10d225306ad102b57408e2ef7566bcfb829b2..refs/remotes/upstream/main ``` ## Results | Check | Result | |---|---| | Merge preview | Clean | | Diff check | Passed; no output | | Hosted conventions and Windows | Passed | | Focused AMD tests | Author reports 18/18 on this head and 16/16 on main at `08a10d2`; not independently run | | Performance evidence | No new same-title, same-scene, same-machine main/change capture pair is present | ## Findings ### Blocking - The PR remains labeled `perf`, while the new report is a correctness run and supplies no matched performance captures or the required report artifacts. This leaves the stated performance result unverified. - The new focused tests use main at `08a10d2`. Current main has since changed the shared graphics test file; the reported pair therefore does not cover the latest test tree. ## Not verified I did not run a local build, GPU tests, or a performance capture. ## To get this to a good state Please attach the required matched main/change performance captures for the same title, scene, and machine, including both `aps5-summary.jsonl` lines, traces, and `tools/trace_digest.py` output. Please also rerun the focused main/change tests using current main `5ecef09` (or the corresponding exact merge tree). I’ll rerun the same source checks on the new head.
Sign in to join this conversation.
No reviewers
No labels
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
boykopovar/AnyPS5!8874
No description provided.