HLE: account for DirectStorage decode intermediates #836

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

@⁠Filip722 on GitHub · 2026-11-25 09:53 UTC · original
Filip722:hle/dstorage-combined-decode-staging → main · +46 −5 · 1 files · 1 commits · open

Combined zlib and BCPack reads allocate a buffer for the BCPack stream while the zlib input is still live. The scheduler now adds that intermediate buffer to the staging reservation. File-backed requests also reserve their owned source buffer. Memory-backed requests borrow their input.

Two synthetic cases submit a pair of decodes against a 100-byte budget. Their intermediate is 60 bytes, with 20 more bytes of owned input for the file case. Both tests require the second job to wait and then start after the first releases its reservation.

  • Test-only control at 9376fd6: both new cases reproduced premature admission, with the existing staging test passing.
  • Patched Windows MSVC release harness with Rust 1.98.1 under GE-Proton 11-14: all three staging tests passed.
  • The repository asset-policy check passed. Both test arms used only synthetic requests.

OpenAI Codex (GPT-6.2-Sol High) prepared and reviewed the patch, ran the comparison, and drafted this description.

**@⁠Filip722** on GitHub · 2026-11-25 09:53 UTC · [original](https://github.com/fxceless/victory-fork/pull/836) `Filip722:hle/dstorage-combined-decode-staging` → `main` · +46 −5 · 1 files · 1 commits · open Combined zlib and BCPack reads allocate a buffer for the BCPack stream while the zlib input is still live. The scheduler now adds that intermediate buffer to the staging reservation. File-backed requests also reserve their owned source buffer. Memory-backed requests borrow their input. Two synthetic cases submit a pair of decodes against a 100-byte budget. Their intermediate is 60 bytes, with 20 more bytes of owned input for the file case. Both tests require the second job to wait and then start after the first releases its reservation. - Test-only control at `9376fd6`: both new cases reproduced premature admission, with the existing staging test passing. - Patched Windows MSVC release harness with Rust 1.98.1 under GE-Proton 11-14: all three staging tests passed. - The repository asset-policy check passed. Both test arms used only synthetic requests. OpenAI Codex (GPT-6.2-Sol High) prepared and reviewed the patch, ran the comparison, and drafted this description.
Count the zlib-to-BCPack intermediate against staging while combined requests run. A synthetic lane regression covers borrowed memory sources and file sources whose input overlaps the intermediate.

Assisted-by: OpenAI Codex
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-26 03:52:11 +00:00
Author
Owner

@⁠MamaLeVrai on GitHub · 2026-11-25 12:23 UTC · original · edited 2026-11-25 12:51 UTC

Test report on real hardware: AMD RX 6950 XT (RDNA2), Windows 11, Rust 1.98.1, with a GPU present. I merged this PR's head c4dd786 into main f85101b in a throwaway tree (no conflict). cargo clippy --workspace --all-targets --locked -- -D warnings fails with the errors main itself has on this machine (placed_filler_twins, depth_written, a sort, and manual implementation of .is_multiple_of() at victory-gpu/src/shadow.rs:2675; PR #841 fixes the first three), also with --all-features; this PR adds none. (Correction: my first version of this report said that the is_multiple_of one was extra here. It is in main too: my first baseline run of main did not list it, and a run with --keep-going on a clean main does.) cargo test --workspace --locked: run 1: stopped at indirect::tests::warp_budget_saturates_without_wraparound_and_preserves_draw_fields (the one that fails on main itself most runs here (PR #849 and #847 fix its assertion)); run 2: 567 passed, 0 failed, 12 ignored (main alone: 555 passed, 0 failed, 11 ignored). The title was not run, so this says nothing about in-game effect. No game data.

AI-assisted (Claude Code); no game data.

**@⁠MamaLeVrai** on GitHub · 2026-11-25 12:23 UTC · [original](https://github.com/fxceless/victory-fork/pull/836#issuecomment-7162312611) · edited 2026-11-25 12:51 UTC Test report on real hardware: AMD RX 6950 XT (RDNA2), Windows 11, Rust 1.98.1, with a GPU present. I merged this PR's head `c4dd786` into `main` `f85101b` in a throwaway tree (no conflict). `cargo clippy --workspace --all-targets --locked -- -D warnings` fails with the errors `main` itself has on this machine (`placed_filler_twins`, `depth_written`, a sort, and `manual implementation of .is_multiple_of()` at `victory-gpu/src/shadow.rs:2675`; PR #841 fixes the first three), also with `--all-features`; this PR adds none. (Correction: my first version of this report said that the `is_multiple_of` one was extra here. It is in `main` too: my first baseline run of `main` did not list it, and a run with `--keep-going` on a clean `main` does.) `cargo test --workspace --locked`: run 1: stopped at `indirect::tests::warp_budget_saturates_without_wraparound_and_preserves_draw_fields` (the one that fails on `main` itself most runs here (PR #849 and #847 fix its assertion)); run 2: 567 passed, 0 failed, 12 ignored (`main` alone: 555 passed, 0 failed, 11 ignored). The title was not run, so this says nothing about in-game effect. No game data. AI-assisted (Claude Code); no game data.
Author
Owner

@⁠Filip722 on GitHub · 2026-11-25 21:31 UTC · original · edited 2026-11-26 08:55 UTC

I retested this PR on fork main c36971b in a local integration with #830. The Rust 1.98.1 Windows MSVC release test binary ran all three staging_bounds_ cases under GE-Proton 11-14. All three passed, including both combined-decode cases. The requests were synthetic. Codex (GPT-6.2-Sol High) ran the retest.

**@⁠Filip722** on GitHub · 2026-11-25 21:31 UTC · [original](https://github.com/fxceless/victory-fork/pull/836#issuecomment-7175194369) · edited 2026-11-26 08:55 UTC I retested this PR on fork main `c36971b` in a local integration with #830. The Rust 1.98.1 Windows MSVC release test binary ran all three `staging_bounds_` cases under GE-Proton 11-14. All three passed, including both combined-decode cases. The requests were synthetic. Codex (GPT-6.2-Sol High) ran the retest.
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/836/head:github-bot/gh-836'
git switch 'github-bot/gh-836'

Merge

Merge the changes and update on Forgejo.
git switch 'main'
git merge --no-ff 'github-bot/gh-836'
git switch 'github-bot/gh-836'
git rebase 'main'
git switch 'main'
git merge --ff-only 'github-bot/gh-836'
git switch 'github-bot/gh-836'
git rebase 'main'
git switch 'main'
git merge --no-ff 'github-bot/gh-836'
git switch 'main'
git merge --squash 'github-bot/gh-836'
git switch 'main'
git merge --ff-only 'github-bot/gh-836'
git switch 'main'
git merge 'github-bot/gh-836'
git push origin 'main'
This discussion has been locked. Commenting is limited to contributors.
No description provided.