feat(memory): track canonical section generations #408

Closed
github-bot wants to merge 1 commit from github-bot/gh-408 into main AGit
Owner

@⁠krofty on GitHub · 2026-11-27 21:58 UTC · original
feat/377-section-identity → main · +2707 −83 · 6 files · 1 commits · closed without merging

The in-place census identifies physical pages by a reusable section handle and offset. That is insufficient for rejecting stale mappings, reused physical allocations or delayed write observations. GPU ownership needs a canonical identity before it can safely omit publication.

Add backing tokens, physical allocation incarnations, logical ranges, mapping epochs and observed byte-range versions. The existing alias census and identity bindings share one registry lock. Native sections retain one token for their lifetime; mapping callbacks carry it, stale explicit tokens are rejected before changing the census, and physical retirement/rearrangement runs inside mapping exclusion. Temporary physical I/O windows retain the actual section identity through their final write notification.

Write guards use a bounded atomic fault journal; mapping changes retain tombstones and fall back conservatively on incomplete observations. Native kernel writes report both beginning and completion. This reuses the identity core from our earlier shared-storage work without importing its retention/capture paths.

Refs #377 and Snaacky/ztrx#249. Affected files are storage.rs, its native CPU fixture, inplace.rs, watch.rs, lib.rs and xmem.rs.

Validation:

  • 26 identity regressions, eight existing census regressions and38 guard regressions pass.
  • A native CPU fixture maps two real aliases, checks shared write versions, executes a guarded store through the actual VEH, reincarnates physical pages and reuses a VA while rejecting stale leases.
  • Physical-window lifetime after PFN release and retirement exclusion against a live native mapping reader both pass.
  • Both affected crates compile with diagnostics and pass ordinary cargo check without diagnostics. New modules pass rustfmt; git diff --check passes. Unused metadata APIs produce warnings while ownership consumers remain pending.

Diagnostics build300 and fixed-world off/on runs321/322 passed closure with no reported errors. Last three host intervals were47.6/48.6/47.6ms off and47.0/46.3/48.3ms on; expected geometry is present in both pictures. This establishes initial compatibility, not an FPS gain or completed-frame distribution.

This is a foundation stage. tracking_complete remains false. No eager GPU readback, comparison or legacy refresh is skipped; GPU publication origin, full I/O leases, before-exposure mapping admission and GPU ownership are dependent work. No30FPS qualification is claimed. Draft PR remains open and unmerged.

**@⁠krofty** on GitHub · 2026-11-27 21:58 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/408) `feat/377-section-identity` → `main` · +2707 −83 · 6 files · 1 commits · closed without merging The in-place census identifies physical pages by a reusable section handle and offset. That is insufficient for rejecting stale mappings, reused physical allocations or delayed write observations. GPU ownership needs a canonical identity before it can safely omit publication. Add backing tokens, physical allocation incarnations, logical ranges, mapping epochs and observed byte-range versions. The existing alias census and identity bindings share one registry lock. Native sections retain one token for their lifetime; mapping callbacks carry it, stale explicit tokens are rejected before changing the census, and physical retirement/rearrangement runs inside mapping exclusion. Temporary physical I/O windows retain the actual section identity through their final write notification. Write guards use a bounded atomic fault journal; mapping changes retain tombstones and fall back conservatively on incomplete observations. Native kernel writes report both beginning and completion. This reuses the identity core from our earlier shared-storage work without importing its retention/capture paths. Refs #377 and Snaacky/ztrx#249. Affected files are storage.rs, its native CPU fixture, inplace.rs, watch.rs, lib.rs and xmem.rs. Validation: - 26 identity regressions, eight existing census regressions and38 guard regressions pass. - A native CPU fixture maps two real aliases, checks shared write versions, executes a guarded store through the actual VEH, reincarnates physical pages and reuses a VA while rejecting stale leases. - Physical-window lifetime after PFN release and retirement exclusion against a live native mapping reader both pass. - Both affected crates compile with diagnostics and pass ordinary cargo check without diagnostics. New modules pass rustfmt; git diff --check passes. Unused metadata APIs produce warnings while ownership consumers remain pending. Diagnostics build300 and fixed-world off/on runs321/322 passed closure with no reported errors. Last three host intervals were47.6/48.6/47.6ms off and47.0/46.3/48.3ms on; expected geometry is present in both pictures. This establishes initial compatibility, not an FPS gain or completed-frame distribution. This is a foundation stage. tracking_complete remains false. No eager GPU readback, comparison or legacy refresh is skipped; GPU publication origin, full I/O leases, before-exposure mapping admission and GPU ownership are dependent work. No30FPS qualification is claimed. Draft PR remains open and unmerged.
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-27 22:03:51 +00:00
github-bot closed this pull request 2026-11-28 01:24:26 +00:00

Pull request closed

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!408
No description provided.