mirror of
https://github.com/tangerineturtle1/NX2navi.git
synced 2026-11-21 12:19:58 -04:00
Count the low-latency driver's sleep as pacing on whichever thread acquires, as the other acquire waits are counted since the pacing timing changed: vk_lowlat.c frame_begin runs on the acquiring thread, which need not be the one that presents, and perf_end dropped a wait made there.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -267,7 +267,7 @@ static void frame_begin(uint64_t id, int at_input) {
|
|||||||
uint64_t p0 = perf_begin();
|
uint64_t p0 = perf_begin();
|
||||||
if (L.kind == LL_NV) nv_sleep();
|
if (L.kind == LL_NV) nv_sleep();
|
||||||
else STORE(&L.staged[id % RING], id), amd_stage(VK_ANTI_LAG_STAGE_INPUT_AMD, id);
|
else STORE(&L.staged[id % RING], id), amd_stage(VK_ANTI_LAG_STAGE_INPUT_AMD, id);
|
||||||
perf_end(PERF_PACE, p0);
|
perf_end_any(PERF_PACE, p0); // the acquiring thread may not be the one that presents
|
||||||
kern_core_back(&away);
|
kern_core_back(&away);
|
||||||
__atomic_add_fetch(&L.sleep_ns, kern_now_ns() - t0, __ATOMIC_RELAXED);
|
__atomic_add_fetch(&L.sleep_ns, kern_now_ns() - t0, __ATOMIC_RELAXED);
|
||||||
__atomic_add_fetch(&L.n_sleep, 1, __ATOMIC_RELAXED);
|
__atomic_add_fetch(&L.n_sleep, 1, __ATOMIC_RELAXED);
|
||||||
|
|||||||
Reference in New Issue
Block a user