gpu: retain certified section pages until CPU demand #420

Closed
opened 2026-11-27 22:12:49 +00:00 by krofty · 4 comments
krofty commented 2026-11-27 22:12:49 +00:00 (Migrated from github.com)
Contributor

Imported from trustno1-coder/VIctory-NVIDIA. Originally posted by krofty on 2026-11-27T22:12:49Z.


The working RTX3070 scene still takes about48–51ms/frame. Batching removed roughly90% of maintenance launches without improving FPS. The larger target is repeated scans and eager publication of GPU-produced bytes whose consumers can keep using the same GPU representation.

Implement one bounded, fail-closed vertical slice: certified ownership of complete64KiB section-backed pages in a card-resident buffer. This builds on canonical section identities in #377/#408 and the existing shared-storage objective Snaacky/ztrx#249. It must provide actual selective publication, not treat observed versions as an ownership proof.

Required behavior:

  • Admit pages only with an exact completed full-page image, matching CPU reference/guest bytes, current physical incarnation/alias epochs, latest producer and upload watermark. Interlock read-only-to-NOACCESS admission with CPU stores and mappings.
  • Retain a canonical GPU owner and exact native producer receipts. Same-owner GPU writes/consumers stay on-card; suppress compare/eager fetch only for certified pieces. Preserve complete shader footprints and indirect safety.
  • A native CPU load/store demands the latest page. Fetch into immutable storage using correctly ordered DIRECT work; release queue-order locks before CPU waits; preserve live-source protection and fence-based retirement. Publish through the hidden section alias while all guest aliases remain inaccessible, then commit generations/reference bytes before reopening.
  • CPU writes establish a floor rejecting older images. Remap/reuse, newer GPU writers, competing mirrors/windows, texture aliases and unknown imports must not resurrect stale bytes; use eager fallback or demand publication where proof is incomplete.
  • Physical I/O and new mappings require CPU admission before exposure. Snapshot plans under short table locks, materialize outside them, revalidate after reacquisition. No GPU wait under Physical/PAGES/Registry/VM locks, and no native-reader-to-VM-writer upgrade.
  • Bound retained resources by actual backing cost and avoid per-page producer-update overhead. Use current VRAM-resident buffers; keep shared control data on appropriate CPU-visible paths. Feature stays off until complete-path proof.

Validation: synthetic native aliases, two queued GPU writers, a delayed old image after CPU modification, remap/reuse, active I/O, same-owner GPU consumption, and resource retirement. Run WARP/RTX fixtures serially; then fixed-world matched runs via build.sh/one.sh/TIMING=1, pictures, actual skipped bytes/dispatches and CPU demand counters. No missing rendering or overlapping timers count as a win. No30FPS claim without completed-frame qualification.

Claim: Codex/krofty on its own branch, with #408 as a prerequisite. Fresh overlap checks protect Snaacky's raw-pixel work and other authors' open memory/fill/buffer-state/physical-number branches. Do not import the old quiescence/capture architecture wholesale, modify author branches or merge PRs. Private game data stays local.

<!-- greyfinch-sync:trustno1-coder/VIctory-NVIDIA:issue:6655277641 --> Imported from [trustno1-coder/VIctory-NVIDIA](https://github.com/trustno1-coder/VIctory-NVIDIA/issues/420). Originally posted by [krofty](https://github.com/krofty) on 2026-11-27T22:12:49Z. --- The working RTX3070 scene still takes about48–51ms/frame. Batching removed roughly90% of maintenance launches without improving FPS. The larger target is repeated scans and eager publication of GPU-produced bytes whose consumers can keep using the same GPU representation. Implement one bounded, fail-closed vertical slice: certified ownership of complete64KiB section-backed pages in a card-resident buffer. This builds on canonical section identities in #377/#408 and the existing shared-storage objective Snaacky/ztrx#249. It must provide actual selective publication, not treat observed versions as an ownership proof. Required behavior: - Admit pages only with an exact completed full-page image, matching CPU reference/guest bytes, current physical incarnation/alias epochs, latest producer and upload watermark. Interlock read-only-to-NOACCESS admission with CPU stores and mappings. - Retain a canonical GPU owner and exact native producer receipts. Same-owner GPU writes/consumers stay on-card; suppress compare/eager fetch only for certified pieces. Preserve complete shader footprints and indirect safety. - A native CPU load/store demands the latest page. Fetch into immutable storage using correctly ordered DIRECT work; release queue-order locks before CPU waits; preserve live-source protection and fence-based retirement. Publish through the hidden section alias while all guest aliases remain inaccessible, then commit generations/reference bytes before reopening. - CPU writes establish a floor rejecting older images. Remap/reuse, newer GPU writers, competing mirrors/windows, texture aliases and unknown imports must not resurrect stale bytes; use eager fallback or demand publication where proof is incomplete. - Physical I/O and new mappings require CPU admission before exposure. Snapshot plans under short table locks, materialize outside them, revalidate after reacquisition. No GPU wait under Physical/PAGES/Registry/VM locks, and no native-reader-to-VM-writer upgrade. - Bound retained resources by actual backing cost and avoid per-page producer-update overhead. Use current VRAM-resident buffers; keep shared control data on appropriate CPU-visible paths. Feature stays off until complete-path proof. Validation: synthetic native aliases, two queued GPU writers, a delayed old image after CPU modification, remap/reuse, active I/O, same-owner GPU consumption, and resource retirement. Run WARP/RTX fixtures serially; then fixed-world matched runs via build.sh/one.sh/TIMING=1, pictures, actual skipped bytes/dispatches and CPU demand counters. No missing rendering or overlapping timers count as a win. No30FPS claim without completed-frame qualification. Claim: Codex/krofty on its own branch, with #408 as a prerequisite. Fresh overlap checks protect Snaacky's raw-pixel work and other authors' open memory/fill/buffer-state/physical-number branches. Do not import the old quiescence/capture architecture wholesale, modify author branches or merge PRs. Private game data stays local.
github-actions[bot] commented 2026-11-27 22:12:57 +00:00 (Migrated from github.com)
Author
Contributor

Imported from trustno1-coder/VIctory-NVIDIA. Originally posted by github-actions[bot] on 2026-11-27T22:12:57Z.


Please attach both logs from the run that went wrong. Without them we can only guess. Paste %LOCALAPPDATA% into the address bar of File Explorer to get there.

  1. The play log, in %LOCALAPPDATA%\victory\logs\: the newest victory-nvidia-play-<date>-<time>-<number>.log (from victory.exe) or victory-nvidia-<date>-<time>.log (from the script launcher). The window shows its path at the start, on the line Log: ....
  2. The crash log: %LOCALAPPDATA%\VIctory\data\7952987A\crashes.log, and, if there is one from that run, the newest victory-<date>-<time>-<number>.crash.log in %LOCALAPPDATA%\VIctory\data\7952987A\temp\.

Also say which GPU, Windows version (10 or 11)

<!-- greyfinch-sync:trustno1-coder/VIctory-NVIDIA:comment:7229129191 --> Imported from [trustno1-coder/VIctory-NVIDIA](https://github.com/trustno1-coder/VIctory-NVIDIA/issues/420#issuecomment-7229129191). Originally posted by [github-actions[bot]](https://github.com/apps/github-actions) on 2026-11-27T22:12:57Z. --- Please attach both logs from the run that went wrong. Without them we can only guess. Paste `%LOCALAPPDATA%` into the address bar of File Explorer to get there. 1. The play log, in `%LOCALAPPDATA%\victory\logs\`: the newest `victory-nvidia-play-<date>-<time>-<number>.log` (from `victory.exe`) or `victory-nvidia-<date>-<time>.log` (from the script launcher). The window shows its path at the start, on the line `Log: ...`. 2. The crash log: `%LOCALAPPDATA%\VIctory\data\7952987A\crashes.log`, and, if there is one from that run, the newest `victory-<date>-<time>-<number>.crash.log` in `%LOCALAPPDATA%\VIctory\data\7952987A\temp\`. Also say which GPU, Windows version (10 or 11)
krofty commented 2026-11-27 23:23:41 +00:00 (Migrated from github.com)
Author
Contributor

Imported from trustno1-coder/VIctory-NVIDIA. Originally posted by krofty on 2026-11-27T23:23:41Z.


Codex/krofty continues the existing claim on a separate local task branch. The bounded implementation is in place behind an off-by-default switch: complete section-page ownership, native DIRECT producer receipts and demand capture, original-identity landing stamps, remap/I/O admission and CPU-reference invalidation. Unsupported queue/maintenance combinations fail explicitly.

Diagnostics compilation and focused ownership, landing, staging, identity and alias/write-watch tests pass. Asset-free production-path fixtures pass on WARP and an RTX 3070 with the D3D12 debug layer: latest pending writer, CPU alias demand, stale-image rejection, canceled watch preserving CPU bytes, retained-plan rejection before Execute, partial-remap legacy landing, unchanged-neighbor publication and native resource retirement. No D3D12 debug errors reported.

The broader HLE remapping regression exposed a parallel-worker admission bug: transient controller contention was being reported as a mapping failure despite a retained outer physical admission. That is being corrected before game validation. No FPS improvement or 30 FPS claim yet. The feature remains off and no PR will be merged without the user's instruction. Other authors' open branches remain untouched.

<!-- greyfinch-sync:trustno1-coder/VIctory-NVIDIA:comment:7230106560 --> Imported from [trustno1-coder/VIctory-NVIDIA](https://github.com/trustno1-coder/VIctory-NVIDIA/issues/420#issuecomment-7230106560). Originally posted by [krofty](https://github.com/krofty) on 2026-11-27T23:23:41Z. --- Codex/krofty continues the existing claim on a separate local task branch. The bounded implementation is in place behind an off-by-default switch: complete section-page ownership, native DIRECT producer receipts and demand capture, original-identity landing stamps, remap/I/O admission and CPU-reference invalidation. Unsupported queue/maintenance combinations fail explicitly. Diagnostics compilation and focused ownership, landing, staging, identity and alias/write-watch tests pass. Asset-free production-path fixtures pass on WARP and an RTX 3070 with the D3D12 debug layer: latest pending writer, CPU alias demand, stale-image rejection, canceled watch preserving CPU bytes, retained-plan rejection before Execute, partial-remap legacy landing, unchanged-neighbor publication and native resource retirement. No D3D12 debug errors reported. The broader HLE remapping regression exposed a parallel-worker admission bug: transient controller contention was being reported as a mapping failure despite a retained outer physical admission. That is being corrected before game validation. No FPS improvement or 30 FPS claim yet. The feature remains off and no PR will be merged without the user's instruction. Other authors' open branches remain untouched.
krofty commented 2026-11-28 00:50:18 +00:00 (Migrated from github.com)
Author
Contributor

Imported from trustno1-coder/VIctory-NVIDIA. Originally posted by krofty on 2026-11-28T00:50:18Z.


The HLE parallel-mapping admission regression is fixed and its tests pass. Game validation then exposed a distinct freeze race: CPU demands after preparation introduced new stale CPU-reference intervals. A native negative fixture reproduces the old failure; the fix refreshes only those newly CPU-owned intervals under the final admission/freeze pins before upload submission. The strict stale-reference check remains in place.

The next game run passed that failure but stopped at the title's save-loading error, so it is not a valid world performance sample. It also revealed overly broad ownership selection: CPU-initialized pages could be admitted despite no GPU-output comparison. Selection now requires the plan's completed native Main/checker fence, a changed declared full page and the original mapping witness, revalidated during admission and sealing. Upload-only and remapped pages cannot inherit eligibility. The exact cause of the save error is not established; metadata-only save-read tracing is enabled for the next run.

All twelve current regression groups pass, including HLE mappings, guard mode on/off, the expected-failure old-freeze negative, and real WARP/RTX 3070 producer/checker/demand tests with the D3D12 debug layer. A fresh diagnostics build is now running in the game. No valid ownership-enabled world FPS result, matched-pair improvement or 30 FPS achievement is claimed. Feature remains off by default; public PR preparation preserves public-only ancestry and no PR will be merged without the user's instruction.

<!-- greyfinch-sync:trustno1-coder/VIctory-NVIDIA:comment:7231227887 --> Imported from [trustno1-coder/VIctory-NVIDIA](https://github.com/trustno1-coder/VIctory-NVIDIA/issues/420#issuecomment-7231227887). Originally posted by [krofty](https://github.com/krofty) on 2026-11-28T00:50:18Z. --- The HLE parallel-mapping admission regression is fixed and its tests pass. Game validation then exposed a distinct freeze race: CPU demands after preparation introduced new stale CPU-reference intervals. A native negative fixture reproduces the old failure; the fix refreshes only those newly CPU-owned intervals under the final admission/freeze pins before upload submission. The strict stale-reference check remains in place. The next game run passed that failure but stopped at the title's save-loading error, so it is not a valid world performance sample. It also revealed overly broad ownership selection: CPU-initialized pages could be admitted despite no GPU-output comparison. Selection now requires the plan's completed native Main/checker fence, a changed declared full page and the original mapping witness, revalidated during admission and sealing. Upload-only and remapped pages cannot inherit eligibility. The exact cause of the save error is not established; metadata-only save-read tracing is enabled for the next run. All twelve current regression groups pass, including HLE mappings, guard mode on/off, the expected-failure old-freeze negative, and real WARP/RTX 3070 producer/checker/demand tests with the D3D12 debug layer. A fresh diagnostics build is now running in the game. No valid ownership-enabled world FPS result, matched-pair improvement or 30 FPS achievement is claimed. Feature remains off by default; public PR preparation preserves public-only ancestry and no PR will be merged without the user's instruction.
trustno1-coder commented 2026-11-29 19:51:43 +00:00 (Migrated from github.com)
Author
Contributor

Imported from trustno1-coder/VIctory-NVIDIA. Originally posted by trustno1-coder on 2026-11-29T19:51:43Z.


Closing this one because it was reported on a build from before v2026.11.28.03 (more than 4 releases ago) and has had no activity since v2026.11.29.01. A lot has changed since then.

If it still happens on the latest release, please open a new issue with the play log and crashes.log from that run. Thanks for reporting!

<!-- greyfinch-sync:trustno1-coder/VIctory-NVIDIA:comment:7261617667 --> Imported from [trustno1-coder/VIctory-NVIDIA](https://github.com/trustno1-coder/VIctory-NVIDIA/issues/420#issuecomment-7261617667). Originally posted by [trustno1-coder](https://github.com/trustno1-coder) on 2026-11-29T19:51:43Z. --- Closing this one because it was reported on a build from before v2026.11.28.03 (more than 4 releases ago) and has had no activity since v2026.11.29.01. A lot has changed since then. If it still happens on the [latest release](https://github.com/trustno1-coder/VIctory-NVIDIA/releases/latest), please open a new issue with the play log and crashes.log from that run. Thanks for reporting!
Sign in to join this conversation.
No labels
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.

Reference
trustno1-coder/VIctory-NVIDIA#420
No description provided.