Skip whole shadows for exact buffer views #948

Closed
Kamiloj9 wants to merge 1 commit from upstream-pr/949 into main
Kamiloj9 commented 2026-11-25 13:31:33 +00:00 (Migrated from github.com)

Imported from fxceless/victory-fork. Originally posted by Kamiloj9 on 2026-11-25T13:31:33Z.


Summary

  • Choose an existing exact byte-range backing before allocating the whole backing when the descriptor's element alignment already requires the exact copy.
  • Use the same selection for host SRV and UAV creation and for refreshing or copying back the view. Ordinary lookups keep their existing selection rules. In-place mode still resolves the actual backing first because its GPU offset can include an extra bias.

Verification

  • A WARP regression creates placed SRV and UAV views requiring an exact 128-byte range. Both host descriptor creation and refresh select the same D3D12 resource, without allocating an unused 4 MiB window. The unchanged code failed the last assertion.
  • On the PR branch, 21 descriptor tests and five shadow-window tests passed, along with workspace all-features and default binary checks and the staged asset policy.
  • A guarded run on the local integration branch stopped at the memory floor before the world-frame marker. Its memory timeline recorded zero exact-copy lookups in that window. This change addresses the allocation in the regression and in workloads that reach that path.
<!-- greyfinch-sync:fxceless/victory-fork:issue:6605628271 --> Imported from [fxceless/victory-fork](https://github.com/fxceless/victory-fork/pull/949). Originally posted by [Kamiloj9](https://github.com/Kamiloj9) on 2026-11-25T13:31:33Z. --- ## Summary - Choose an existing exact byte-range backing before allocating the whole backing when the descriptor's element alignment already requires the exact copy. - Use the same selection for host SRV and UAV creation and for refreshing or copying back the view. Ordinary lookups keep their existing selection rules. In-place mode still resolves the actual backing first because its GPU offset can include an extra bias. ## Verification - A WARP regression creates placed SRV and UAV views requiring an exact 128-byte range. Both host descriptor creation and refresh select the same D3D12 resource, without allocating an unused 4 MiB window. The unchanged code failed the last assertion. - On the PR branch, 21 descriptor tests and five shadow-window tests passed, along with workspace all-features and default binary checks and the staged asset policy. - A guarded run on the local integration branch stopped at the memory floor before the world-frame marker. Its memory timeline recorded zero exact-copy lookups in that window. This change addresses the allocation in the regression and in workloads that reach that path.
upstream-sync closed this pull request 2026-11-26 01:06:01 +00:00

Pull request closed

Sign in to join this conversation.
No reviewers
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
fxceless/victory-fork!948
No description provided.