Compare descriptor records at their fixed slot widths #3038

Open
github-bot wants to merge 1 commit from github-bot/gh-3038 into main AGit
Owner

@⁠Brazzo978 on GitHub · 2026-11-29 19:41 UTC · original
Brazzo978:perf/fixed-width-descriptor-records → main · +38 −9 · 1 files · 1 commits · open

What it changes

The descriptor heap refresh still skips equal blocks of 16 records. For the blocks that differ, fixed-width arrays let the compiler compare and copy entire 16-byte sampler and 32-byte view records. Changed slot indices remain ordered, and an incomplete trailing record is left alone.

How it was tested

I compiled the comparison code with Rust 1.98.1 MSVC on a Ryzen 7 5800X3D running Windows 10. The three focused tests passed in debug and release. The differential test covered 1,760 cases, including partial tails, with the original implementation as the reference.

Median time per synthetic 4 KiB page

Slot width Changed records Base Patch
16 bytes 0% 286.5 ns 292.0 ns
16 bytes 1% 549.5 ns 343.0 ns
16 bytes 8% 1682.3 ns 608.0 ns
32 bytes 0% 207.7 ns 208.6 ns
32 bytes 1% 295.7 ns 215.4 ns
32 bytes 8% 766.7 ns 307.8 ns

These times cover the CPU compare and copy only. Gameplay frame time for this patch has not been measured.

The two focused victory-gpu crate tests passed on Windows MSVC, including the partial-tail regression.

Checked for overlap

  • Searched open PRs for the descriptor refresh and comparison. #2998 covers descriptor completion and scratch reuse. #2956 bounds a descriptor query range. #2174 changes address publication after the comparison.
**@⁠Brazzo978** on GitHub · 2026-11-29 19:41 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/3038) `Brazzo978:perf/fixed-width-descriptor-records` → `main` · +38 −9 · 1 files · 1 commits · open ## What it changes The descriptor heap refresh still skips equal blocks of 16 records. For the blocks that differ, fixed-width arrays let the compiler compare and copy entire 16-byte sampler and 32-byte view records. Changed slot indices remain ordered, and an incomplete trailing record is left alone. ## How it was tested I compiled the comparison code with Rust 1.98.1 MSVC on a Ryzen 7 5800X3D running Windows 10. The three focused tests passed in debug and release. The differential test covered 1,760 cases, including partial tails, with the original implementation as the reference. Median time per synthetic 4 KiB page | Slot width | Changed records | Base | Patch | | --- | ---: | ---: | ---: | | 16 bytes | 0% | 286.5 ns | 292.0 ns | | 16 bytes | 1% | 549.5 ns | 343.0 ns | | 16 bytes | 8% | 1682.3 ns | 608.0 ns | | 32 bytes | 0% | 207.7 ns | 208.6 ns | | 32 bytes | 1% | 295.7 ns | 215.4 ns | | 32 bytes | 8% | 766.7 ns | 307.8 ns | These times cover the CPU compare and copy only. Gameplay frame time for this patch has not been measured. The two focused `victory-gpu` crate tests passed on Windows MSVC, including the partial-tail regression. ## Checked for overlap - [x] Searched open PRs for the descriptor refresh and comparison. #2998 covers descriptor completion and scratch reuse. #2956 bounds a descriptor query range. #2174 changes address publication after the comparison.
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-29 19:47:09 +00:00
This pull request can be merged automatically.
This branch is out-of-date with the base branch
You are not authorized to merge this pull request.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin '+refs/pull/3038/head:github-bot/gh-3038'
git switch 'github-bot/gh-3038'

Merge

Merge the changes and update on Forgejo.
git switch 'main'
git merge --no-ff 'github-bot/gh-3038'
git switch 'github-bot/gh-3038'
git rebase 'main'
git switch 'main'
git merge --ff-only 'github-bot/gh-3038'
git switch 'github-bot/gh-3038'
git rebase 'main'
git switch 'main'
git merge --no-ff 'github-bot/gh-3038'
git switch 'main'
git merge --squash 'github-bot/gh-3038'
git switch 'main'
git merge --ff-only 'github-bot/gh-3038'
git switch 'main'
git merge 'github-bot/gh-3038'
git push origin 'main'
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!3038
No description provided.