mirror of
https://github.com/boykopovar/AnyPS5.git
synced 2026-11-04 13:07:32 +00:00
The graphics pipeline store kept a fixed 1024 entries and the pipeline journal replayed at most 1024 records, and a replayed pipeline that found the store full was dropped. A title whose working set is larger rebuilt the rest at the draw on every run, and evicted pipelines it kept using were rebuilt again and again. The bound now starts at 1024 and doubles up to 4096: a journal replay that does not fit grows it instead of dropping the pipeline, and so does eviction churn (a ghost list of evicted keys, checked every bound/32 evictions: more than half of them came back). It never shrinks during a run; APS5_PIPELINE_STORE_ENTRIES still fixes it. The journal loads its last 4096 records by default (APS5_PIPELINE_JOURNAL_ENTRIES). Resident pipelines are bounded by count, not bytes. agc_driver_recorder_tests --benchmark-pipeline-store-memory [count] (opt-in, not registered) builds count graphics pipelines with one fragment module each through CachedPipeline and prints process private bytes and VK_EXT_memory_budget heap usage before and after: with the triangle shaders about 59 KiB host and no device memory per pipeline on an RTX 4090, 100 KiB host and 8 KiB device-local on a UHD 770. Tests: agc_pipeline_store_growth (fails on main), agc_pipeline_store_fixed_bound, agc_pipeline_store_replay_growth (replays on one thread: the mock Vulkan is not thread-safe). Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_017SNUYRd7sRKZrMYpquAsnU