Add diagnostics used to find these fixes, all off by default.

NX2NAVI_TRACE=audio logs voices starting, stopping and sharing a wave buffer; NX2NAVI_DUMP_MOVIE dumps movie frames; NX2NAVI_LOG_CS_BINDS says why the stand-in for an untranslated compute program skipped a dispatch; and NX2NAVI_TRACE=perf adds heap and commit census lines on their own thread, with VMA maps when write-combined memory grows by 2 GiB. From a tester's fixes.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
chrg6
2026-11-08 15:33:49 -05:00
parent ac5c196f3a
commit 0fab109a7f
9 changed files with 262 additions and 28 deletions

View File

@@ -215,6 +215,9 @@ int plat_mem_protect(uint64_t addr, uint64_t n, int prot); // committed pages on
// The page at addr: PLAT_PROT_* when committed, else PLAT_MEM_RESERVED or PLAT_MEM_FREE (not reserved by us). *end
// gets the end of the run of pages in the same state, at most limit.
int plat_mem_state(uint64_t addr, uint64_t limit, uint64_t *end);
// The process's committed private memory and the part of it mapped write-combined (Windows PAGE_WRITECOMBINE: memory
// the GPU driver maps uncached for the CPU), with the number of allocations that part spans. 0 where unsupported.
int plat_mem_census(uint64_t *priv, uint64_t *wc, uint64_t *wc_allocs);
// The pages of a watched reservation written since the last reset, up to max page addresses into pages, in address
// order; reset: those reported start over as unwritten. UINT64_MAX when writes to the range are not tracked.
uint64_t plat_mem_written(uint64_t addr, uint64_t n, uint64_t *pages, uint64_t max, int reset);