From 48ea624389b27ee879bc7b73b2bdcab7a94f4ad9 Mon Sep 17 00:00:00 2001 From: chrg6 Date: Fri, 13 Nov 2026 17:27:35 -0500 Subject: [PATCH] Bring the stutter map's ini text, the checks in docs/building.md and the released-textures bound line in step with the code. - nx2navi.ini.example said the stutter map is written every 10 minutes and at exit; since 7b0dbeb1 it is every 5 minutes of play (stutter_map.c SM_REPORT_NS), at a focus loss in play and at exit, and since 2f640fb8 a run of consecutive long frames counts as one hitch with their summed time. The paragraph now says both. - docs/building.md had no paragraph for tests/freeze_hold_check.py (0e0cfe08), while each other header-alone check has one: it now says what a change to runtime/freeze_hold.h or vk_memory.c freeze_pass must pass and what it checks. - vk_texture.c released_cap_bytes named "a thirty-second of the installed memory" as the source of the bound even when plat_mem_info gave no size and the bound fell back to 1024 MiB; that case now reads "the default without the installed memory's size". Text only. check_content passes; freeze_hold_check passes; vk_texture.c compiles with the dev flags and with -Wall -Wextra with the one warning it had before. Co-Authored-By: Claude Opus 5.5 --- docs/building.md | 6 ++++++ nx2navi.ini.example | 7 ++++--- runtime/vk_texture.c | 3 ++- 3 files changed, 12 insertions(+), 4 deletions(-) diff --git a/docs/building.md b/docs/building.md index 9671760f..4ec11a7a 100644 --- a/docs/building.md +++ b/docs/building.md @@ -652,6 +652,12 @@ A change to where the lazy write-back is on by default (`runtime/wb_lazy_choice. `vk_mem_lazy_decide`) passes `python tests\wb_lazy_check.py`, which builds the header alone and checks the choice and its reason by platform, by GPU driver and by what the player set. No game files, no GPU. +A change to when the freezing of idle guest regions waits (`runtime/freeze_hold.h`, `runtime/vk_memory.c` +`freeze_pass`) passes `python tests\freeze_hold_check.py`, which builds the header alone: the backoff after a slow +freeze doubles while slow ones come within the quiet time, fast freezes between them included, stops at its cap and +starts over after the quiet time (with a quiet time of 0, at the first fast freeze); and an area load holds the passes +while the texture pool loads and for the hold after it or after the area's load. No GPU, no game files. + A change to what writes `nx2navi.ini` outside the game (`launcher/gameini.py`, `installer/ini.py`, `tools/make_game.py`, `launcher/updater.py`) passes the settings-file tests of `tests\launcher_test.py` (`PlayerIniTest`, and the tests named `..._settings_file` of `BackgroundUpdateTest` and `MakeGameTest`): a player's file with lines that are no settings of diff --git a/nx2navi.ini.example b/nx2navi.ini.example index 13acf908..687b71be 100644 --- a/nx2navi.ini.example +++ b/nx2navi.ini.example @@ -1039,9 +1039,10 @@ # flight_flash_diff = 24 # flight_flash_cells = 3 # Stutter map: the log gets a line for each hitch (a frame over 2.5 times the frames before it and at least 12 ms, or -# over 25 ms) with the area, what the frame waited for and the pipelines and shaders its draws met missing, and every 10 -# minutes and at exit a map of the areas by their hitches and of the pipelines that cost the most. tools/stutter_map.py -# reads it. 0: off. Read at start. +# over 25 ms) with the area, what the frame waited for and the pipelines and shaders its draws met missing; a run of +# consecutive long frames counts as one hitch with their summed time. Every 5 minutes of play, when the window loses +# the focus in play and at exit, a map of the areas by their hitches and of the pipelines that cost the most. +# tools/stutter_map.py reads it. 0: off. Read at start. # stutter_map = 0 # GPU pass marks: after a GPU crash (device lost) the log names the render pass or dispatch the GPU had started and the # last one it finished. Unset: on AMD GPUs (VK_AMD_buffer_marker). 1: also on NVIDIA GPUs diff --git a/runtime/vk_texture.c b/runtime/vk_texture.c index efc2b932..a9975e34 100644 --- a/runtime/vk_texture.c +++ b/runtime/vk_texture.c @@ -2547,7 +2547,8 @@ static uint64_t released_cap_bytes(void) { plat_mem_info(&used, &total, &proc); mb = total > 0 ? (long long)(total / 32) : 1024; mb = mb < 512 ? 512 : mb > 2048 ? 2048 : mb; - by = ", a thirty-second of the installed memory (512 MiB to 2 GiB)"; + by = total > 0 ? ", a thirty-second of the installed memory (512 MiB to 2 GiB)" + : ", the default without the installed memory's size"; // By the card too: a quarter of its budget where the PC has an eighth of its memory to match, up to // RELEASED_CAP_MAX_MB. The game lets go of the textures of what leaves the view and takes them back when // it returns; walking through a village the released ones passed 1 GiB within two or three minutes, and