Diagnostics/process memory snapshot #484
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/484"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Imported from Marvisak/VIctory. Originally posted by ToxicmaggotRP on 2026-11-24T03:57:25Z.
Diagnostics: report process private and resident memory
Related to #471 (memory growth during world load).
What
The diagnostics copy-stat line already samples process page faults through
K32GetProcessMemoryInfo, but it only requests the basePROCESS_MEMORY_COUNTERSstructure.This change adds the extended counters needed to correlate copy-path measurements with the process's actual memory footprint:
PROCESS_MEMORY_COUNTERS_EX.PrivateUsage(process private commit charge) andWorkingSetSize(resident working set) in GiB.This is process-wide telemetry. It does not attribute memory to individual pools or staging buffers, and it does not fix the memory ceiling by itself. It provides a reliable process-memory series to compare with existing copy statistics and the memory optimisations in #472.
Verification
windows-sys 0.61.2API signature and structure fields.PROCESS_MEMORY_COUNTERS_EX.crates/victory-gpu/src/copystat.rschanges.main, with no upstream commits missing.cargo fmt,cargo check -p victory-gpu --features diagnostics, tests, and a Windows diagnostics run were not performed because Rust/Cargo are unavailable in the development environment.No game assets or proprietary files used.
AI-assisted contribution (ChatGPT).
upstream-sync referenced this pull request2026-11-24 06:53:55 +00:00
Imported from Marvisak/VIctory. Originally posted by mercuryVM on 2026-11-24T09:13:35Z.
Review: APPROVED
Tested
3b7e1d5on Windows 11, RTX 5070, MSVC: the workspace passes (264: 195 outsidevictory-shader, plusvictory-shader --libwith--test-threads=1, 69 passed). The first full run timed out on the known parallel VALU GPU-test hang that #433 addresses, which has nothing to do with this change.cargo check -p victory-gpu --features diagnosticsis clean.K32GetProcessMemoryInfowithcb = size_of::<PROCESS_MEMORY_COUNTERS_EX>()and the base-struct pointer cast is the documented way to getPrivateUsage.PrivateUsage(commit) andWorkingSetSize(resident) are the two numbers #471 needs.Diagnostics only, so release builds are unchanged. No issues found.
AI-assisted (Claude Code).
upstream-sync referenced this pull request2026-11-24 19:03:41 +00:00
Pull request closed