Skip to content

GPU: find shadow buffers past smaller placed entries - #51

Merged
devin-ai-integration[bot] merged 2 commits into
mainfrom
devin/shadow-enclosing
Nov 25, 2026
Merged

devin-ai-integration[bot] merged 2 commits into
mainfrom
devin/shadow-enclosing

Conversation

@devin-ai-integration

@devin-ai-integration devin-ai-integration Bot commented Nov 25, 2026 •

Copy link
Copy Markdown
Contributor

Summary

Re-ports the buffer-lookup half of upstream #2088 onto the fxceless base.

shadow::lookup and diagnostic extent searched only the 64 buffer registrations starting closest below an address. A heap-sized parent buffer with many smaller placed buffers inside it could be missed, making the range fall through to loose-window copies and duplicate memory that the parent shadow already covered.

The lookup now tracks MAX_SPAN (the longest registered buffer) and searches back only as far as a buffer could still contain the requested range. register also saturates start + len instead of wrapping.

Validation:

  • CARGO_FEATURE_PURE=1 RUSTFLAGS='-D warnings' cargo check --locked -p victory-gpu --all-targets --target x86_64-pc-windows-msvc
  • CARGO_FEATURE_PURE=1 RUSTFLAGS='-D warnings' cargo clippy --locked -p victory-gpu --all-targets --all-features --target x86_64-pc-windows-msvc
  • cargo run --locked --quiet --package xtask -- policy

Linux-hosted cargo test -p victory-gpu remains blocked by the crate's existing Windows-only test compilation (crate::texture, crate::host, host_resource configured out); the new pure-map unit test compiles for the Windows target.

No GPU/game/Proton runtime validation is available in this VM.

Link to Devin session: https://app.devin.ai/sessions/75bbf6b4192940fea34014b13a016bee
Open in Devin Desktop: https://app.devin.ai/desktop/session/75bbf6b4192940fea34014b13a016bee?variant=devin
Requested by: @Personed


🟢 Devin fixed the finding · Follow Devin's work

Devin Review

Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
@devin-ai-integration

Copy link
Copy Markdown
Contributor Author

I'll fix CI failures and address comments from users with write access. I'll skip comments containing "(aside)".

  • Disable automatic comment, CI, and merge conflict monitoring

Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>

@devin-ai-integration devin-ai-integration Bot left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Devin Review found 1 finding. Devin automatically fixed it.

Fixed by Devin (1)
  • Regression coverage beyond 64 entries — The test did fit inside the final small buffer; it now asks just past all 128 small entries so only the parent can contain it.

View findings in Devin Review · Follow Devin's work

Devin Review

@devin-ai-integration
devin-ai-integration Bot merged commit 23610cc into main Nov 25, 2026
5 checks passed
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.

1 participant