Add opt-in GPU memory synchronization tracing #1513
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/1514"
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 draggygaggy-maker on 2026-11-24T18:40:27Z.
Motivation
Related to #1323.
The current
wait_valueimplementation ignores GPU memory waits. Without visibility into their addresses, comparison codes, reference values and associated writes, investigating potential synchronization dependencies is difficult.This PR introduces opt-in diagnostics without implementing or altering the existing wait semantics.
Changes
VICTORY_SYNC_TRACE=1, available in diagnostics builds and disabled by default.Runtime findings
Tested on Windows with an NVIDIA RTX 4060 Ti against upstream commit
ffe310e.During a story intro session:
All observed waits used raw comparison code
7.One address accounted for 3,177 waits (51.7% of all observed waits), with no captured write starting at that exact address. Nearby writes exhibited a repeating three-slot counter pattern with 72-byte spacing.
These observations provide potential investigation targets, not proof of missing synchronization or incorrect counter values. Matching write events include both recording and execution.
Validation
Limitations
This PR does not implement GPU memory waits, interpret comparison code
7, or intentionally change synchronization behavior.The black-world rendering issue persisted during testing. Neither the reported
CrossQueueBarriermessage norDEVICE_HUNGappeared in the captured session log.Pointer identities may be reused, uninstrumented memory writers are not captured, and verbose logging may affect timing.
AI assistance
Developed with assistance from ChatGPT through iterative source inspection, implementation, code review and regression testing. All reported test and runtime results were obtained locally on physical hardware.
Imported from Marvisak/VIctory. Originally posted by pfhandler on 2026-11-24T20:50:20Z.
Local patches for two issues hit while running GTA VI 1.0.2.1 through VIctory on Linux (GE-Proton 11-14, vkd3d-proton 3.2.0, RTX 4060 Ti 8 GB):
VICTORY_NO_HOST_PAD=1— a connected host pad (e.g. DualShock appearing as XInput pad 0) keeps the keyboard stand-in pad from being enumerated. Hiding the host pad letsVICTORY_KEYSdrive the title again.VICTORY_MODE=1920x1080— the DXGI output mode list is fixed at the console's 3840x2160. Reporting 1920x1080 instead keeps the title's render targets and VRAM use down on smaller hosts (Series S profile + 1080p settled around 3.5 GB VRAM here).Both are local uncommitted diffs, posted here for reuse. Tested only on the configuration above.
Imported from Marvisak/VIctory. Originally posted by Marvisak on 2026-11-25T01:29:58Z.
Automated triage for the maintainers.
Needs rebase. This pull request conflicts with
main(conflicting:README.md). It will be reviewed once it is rebased onto the currentmain.Generated by Claude Code
Imported from Marvisak/VIctory. Originally posted by Testaross on 2026-11-30T01:29:03Z.
Hey man, saw your work on GPU memory waits. I’ve been decompiling the original Series X memory subsystem to eventually move away from unified memory translation altogether.
I’ve identified six rotating graphics pools and some of the epoch synchronization logic. Right now I’m trying to figure out exactly when the GPU is done with those allocations and when they can safely be reused.
I’d be interested in comparing your findings with mine. Have you been able to identify what’s actually writing to those wait addresses?
Would you be down to collaborate? I think we might be able to help each other out quite a bit.
View command line instructions
Checkout
From your project repository, check out a new branch and test the changes.Merge
Merge the changes and update on Forgejo.Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.