GPU: card meter and process memory lines in every build #1626

Manually merged
github merged 1 commit from github-bot/gh-1626 into main 2026-11-29 08:21:58 +00:00 AGit
Owner

@⁠mizzied on GitHub · 2026-11-28 22:34 UTC · original
mizzied:up/diagnostic-lines → main · +823 −30 · 7 files · 1 commits · merged 2026-11-29 08:16 UTC

What it adds. Two log lines in every build, not only diagnostic builds:

  • Card meter: the card's time per frame, by kind of command list and by the pipelines they bind. It's read a second after the frames, from timestamp queries.
  • Process memory: committed bytes by owner every 5 s. That's console address ranges (the title's private and mapped memory) against the layer's own heaps and the driver's.

Both help when a report says slow or crashed without a profile. They show where the card's time and the process's memory go from a plain log.

How it was tested. RTX 5070, Windows 11. Five unit tests cover the meter's grouping and reading and the memory line's attribution. cargo test --workspace passes apart from repository_passes_policy, which already fails on main: lower.rs is over the 640 KiB file-size limit there (#1493 raises it). Clippy reports only the 16 findings already on main, none on lines this PR changes. The victory-gpu watch:: tests are flaky on this machine in files this PR does not touch, and pass on a rerun.

**@⁠mizzied** on GitHub · 2026-11-28 22:34 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/1626) `mizzied:up/diagnostic-lines` → `main` · +823 −30 · 7 files · 1 commits · merged 2026-11-29 08:16 UTC **What it adds.** Two log lines in every build, not only diagnostic builds: - **Card meter:** the card's time per frame, by kind of command list and by the pipelines they bind. It's read a second after the frames, from timestamp queries. - **Process memory:** committed bytes by owner every 5 s. That's console address ranges (the title's private and mapped memory) against the layer's own heaps and the driver's. Both help when a report says `slow` or `crashed` without a profile. They show where the card's time and the process's memory go from a plain log. **How it was tested.** RTX 5070, Windows 11. Five unit tests cover the meter's grouping and reading and the memory line's attribution. `cargo test --workspace` passes apart from `repository_passes_policy`, which already fails on `main`: `lower.rs` is over the 640 KiB file-size limit there (#1493 raises it). Clippy reports only the 16 findings already on `main`, none on lines this PR changes. The `victory-gpu` `watch::` tests are flaky on this machine in files this PR does not touch, and pass on a rerun.
Two diagnostics lines that need no diagnostics build and do not change the
frame.

Card meter (cardmeter.rs): a timestamp where each host list begins and ends
(ours that bring the card's copies up to date, ours that compare, every
other), read a second later and printed with the frame-rate line.
VICTORY_CARD_METER=0 turns it off; VICTORY_CARD_METER_PIPELINES=1 adds the
time by pipeline, and every 256 frames the lists by what they bind are
logged. Unlike VICTORY_GPU_TIMING (diagnostics builds, each list sent alone)
it does not change the frame.

Process memory (procmem.rs): every 5 s an address-space walk, on a thread of
its own, splits the committed pages into console addresses (the title's),
host addresses and images, beside counters of what the layer holds (shader
containers, translations, host copies, XMem heap blocks, sections, staging,
upload buffers). copystat's diagnostics-only memory lines are left as they
are and now share process_memory and system_memory with it.

Tests: a list is named by the pipelines it binds; a timestamp pair's length is
in microseconds of the queue's clock; process memory regions are sorted by
owner and the largest at host addresses are named in order; a walk of the
test process finds what it holds.
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-28 22:35:42 +00:00
github manually merged commit 60a1ab7f18 into main 2026-11-29 08:21:58 +00:00
This discussion has been locked. Commenting is limited to contributors.
No reviewers
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
github/trustno1-coder--VIctory-NVIDIA!1626
No description provided.