mirror of
https://github.com/tangerineturtle1/NX2navi.git
synced 2026-11-18 15:19:58 -04:00
Give the longest lazy fetch and the longest wait of a fault for the freeze lock on the "mem: lazy write-back" line.
A fetch of lazily written pages runs inside the fault handler under frz_lock (memory.c lazy_gone_locked and lazy_piece_fetch_locked call vk_memory.c lazy_fetch, a GPU copy after everything handed over and a wait for it), so every other fault, thaw, freeze and arm waits for the whole copy. The line gave only the fetches' sum: the 0.10.0 session's 848 fetches took 415.8 ms in all, and how long one took, or how long another thread waited behind it, was not known. Both fetch sites now keep the longest fetch, and lazy_fault keeps the longest time a fault waited to take frz_lock; the report line prints them as "the longest X ms, faults waited up to Y ms for the freeze lock" and starts both over. No tool parses the line. tests\lazy_fetch_check.py's new report scenario fetches for 30 and 120 ms and has a third fault wait 60 ms for frz_lock: the line reads 120.29 ms and 60.03 ms, and the next one 0.00 for both. arm_race, arm_race_slow, wb_lazy_check and heap_lazy_copy_check passed; memory.c compiles without a warning under -Wall -Wextra. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -691,8 +691,9 @@ its reason by platform, by GPU driver and by what the player set. No game files,
|
||||
A change to the lazy write-back's arms, faults and releases (`runtime/memory.c` "Lazy write-back") passes
|
||||
`python tests\lazy_fetch_check.py`, which builds memory.c with the Windows fault handler and a fetch that only waits,
|
||||
and runs each scenario as its own process, so an access violation fails it: a thread that reads a range over and over
|
||||
while it is armed and given back again never reaches the crash handler, also when the arm's clean test takes 100 ms.
|
||||
Windows only; no game files, no GPU.
|
||||
while it is armed and given back again never reaches the crash handler, also when the arm's clean test takes 100 ms;
|
||||
and the "mem: lazy write-back" line gives the longest fetch and the longest wait of a fault for the freeze lock since
|
||||
the line before. Windows only; 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
|
||||
|
||||
Reference in New Issue
Block a user