Skip to content

GPU: cache exact buffer span unions per heap - #1413

Open
spk-c wants to merge 5 commits into
fxceless:mainfrom
spk-c:submit/descriptor-buffer-spans-v2
Open

spk-c wants to merge 5 commits into
fxceless:mainfrom
spk-c:submit/descriptor-buffer-spans-v2

Conversation

@spk-c

@spk-c spk-c commented Nov 26, 2026

Copy link
Copy Markdown
Contributor

AI-assisted selective adaptation of Kelvaroq 0055 via spk-c#41; source attribution in docs.

Opt-in VICTORY_DESCRIPTOR_BUFFER_SPANS=1 retains the exact enclosing range per backing buffer in the unmarked heap pass. The authoritative slot map, 16-pass revalidation cadence, dirty drain and existing refresh semantics remain unchanged. The index is discarded on inconsistency, full scans, marked-pass reset and heap destruction. The existing marked pass is unchanged. Two CPU oracle tests exercise mixed updates and duplicate endpoints.

This targets span aggregation rather than the descriptor mirroring, lock, and allocation changes of #1293/#1400. No gameplay improvement claimed. Original fork CI passed; direct upstream CI is pending.

Dependencies: existing #1372 (stable heap IDs and cache cleanup, original commit 9aac349) and #1357 (test extraction, original commit 450ed9b). Both are separate, attributed ancestors, not new feature changes. Asset-policy checks and size limit unchanged. When the original dependency commits are merged normally, their changes disappear from this diff.

claude and others added 5 commits November 26, 2026 18:04
…the asset policy's 512 KiB limit

The check job fails on main: crates/victory-gpu/src/host.rs (528,954 bytes)
and crates/victory-shader/src/emit/lower.rs (535,588 bytes) are over the
asset policy's 512 KiB limit (fxceless#1342).

Only #[cfg(test)] modules move, verbatim apart from losing one level of
indentation; module names and paths are unchanged, no non-test code changes.

- host.rs: its eight test modules (tests, relay_tests, grouped_tests,
  late_tests, trail, spare, batch, queue2_tests) move to host/<name>.rs,
  the layout profile.rs and profile/tests.rs already use. 492,495 bytes.
- lower.rs: mod tests moves to emit/lower_tests.rs, declared with
  #[path = "lower_tests.rs"] as in fxceless#1322. 512,559 bytes.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015kFDn6faAxnJwPKPwiCnj1
AI-assisted adaptation to upstream stable heap IDs and marked-pass cache; no cadence changes.
AI-assisted selective adaptation of Kelvaroq 0055 via fork #41; preserves upstream scan cadence and depends on stable heap lifetime fix fxceless#1372.
@spk-c
spk-c marked this pull request as ready for review November 27, 2026 00:05

Copy link
Copy Markdown

Your span cache combines cleanly with KyleS98's table-slot experiment at the current VIctory base. I used Git merge-tree with your head 900c15f5 and #1414 head 9a18dd08. It produced tree a38ce19426925cab2511eb6685c305103dba86b6. I also checked your head with #1411 at dee3f61a; the result was tree f36574568a84b3183368c4756c4d7f914887797d. Both are merge checks, with no behavioral or timing result.

If you compare both descriptor changes, keep the four switch combinations separate. Record the refreshed spans per backing buffer as well as frame time. That will show whether marking more table-owned slots reduces the work your cache is trying to aggregate. You can give a future public PR/target pair to your agent through PortBridge #98 and attach the exact result there for another fork. AI-assisted Git check.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants