mirror of
https://github.com/tangerineturtle1/NX2navi.git
synced 2026-11-19 04:19:57 -04:00
Spread the texture pool's entry creation over frames by a per-frame time budget, and stop looking up the slots it left.
The pool refresh runs before every draw that binds the pools, so its count budget of 16 creations held per draw, not per submission. An area load in the 0.6.1.12 test made 4,925 entries (1.7 GB of uploads) in one 430 ms frame, and 2,018 in a 195 ms one. While slots were left over, every draw walked the whole table and looked each of them up again, about 100 ms of the 430 ms frame in key hashing alone. Once a frame's refreshes have taken pool_create_ms (default 6 ms; 0: no limit), they create nothing more until the next frame, and skip the slots left earlier in the frame. The first refresh of each frame keeps its count budget. The slots left keep their stand-in for a few frames during a large load. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -106,6 +106,10 @@ keeps per-core data without locks and relies on that, so the host models it (`ru
|
||||
skipped as for a translation (`runtime/gfx_shader.c` `load_budget`). Opening a loose file is what costs (5.6 ms a
|
||||
pair the first time on Windows), so an update that carries the shaders over packs the cache once it holds 1,000
|
||||
loose translations (`tools/make_game.py` `PACK_LOOSE_MIN`).
|
||||
- Texture pool streaming: the bindless pool's refresh before each draw creates at most `pool_create_budget` entries,
|
||||
and once a frame's refreshes have taken `pool_create_ms` (6 ms) none more until the next frame; the slots left keep
|
||||
their stand-in, and the frame's later refreshes skip them (`runtime/vk_exec_draw.c` `pool_refill`). An area load
|
||||
spreads over several frames instead of holding one for 200-400 ms.
|
||||
- Mesh and task shaders run as `VK_EXT_mesh_shader`; indirect mesh draws read NVN's `{count, first}` record through a
|
||||
ring of Vulkan `{x, y, z}` records filled on the GPU.
|
||||
- Pipelines: `VK_EXT_graphics_pipeline_library` where the driver has it: stage libraries compiled ahead, a fast link
|
||||
|
||||
Reference in New Issue
Block a user