GPU: improve texture uploads and specialize single-record indirect draws #150
No reviewers
Labels
No labels
accessibility
bug
documentation
duplicate
enhancement
good first issue
help wanted
invalid
question
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/Belobug--VIctory-Belobug-AMD!150
Loading…
Reference in a new issue
No description provided.
Delete branch "github-bot/gh-150"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
@Lkxex on GitHub · 2026-11-25 17:14 UTC · original
Lkxex:port/nov25-belo→main· +729 −37 · 5 files · 5 commits · openThis ports DirectStorage staging, shader signature deduplication, and opt-in texture detiling and indirect draw improvements. GPU detiling runs in the existing upload prelude. The console texture-format change is covered separately by PR 7.
Validation: Windows cargo check passed on the port. In-game behavior and FPS have not been measured.
@KernelSmoker on GitHub · 2026-11-25 17:54 UTC · original
Retested PR head with Qwen stopped and 21.8 GiB free VRAM on the RTX 3090: the same unhandled
0x80000003atvictory-image+0x1ce6e13recurred. This makes VRAM pressure from the local model an unlikely cause of the startup failure.@KernelSmoker on GitHub · 2026-11-25 17:47 UTC · original · edited 2026-11-25 17:57 UTC
I tried an in-game launch of PR head
c30bbeeand its exact basea59f3e5on Bazzite Linux 45, NVIDIA RTX 3090 (host driver 620.73.04), GE-Proton 10-34 / Wine 10.0, vkd3d-proton 3.0.0. Rust 1.98.1 diagnostics builds succeeded for both commits. I usedVICTORY_COPY_MEMORY=1,VICTORY_SPARSE=0, andVICTORY_HAIR=1; the package'sappdata0.rpfwas found and opened.Both commits stop at the same startup point, before frame 1: unhandled
0x80000003atvictory-image-b99f876b74d4a77f.dll+0x1ce6e13during System Init. I repeated PR head withVICTORY_CRASH_BREAKPOINTS=1; the same exception and offset recurred. The crash log records the same stack on both commits.So I could not measure in-game behavior/FPS for this change. The startup failure also reproduces on the PR's base, so this run does not indicate a regression from this PR. No game files or crash dumps are attached.
Correction to the test setup: the executable and appdata0.rpf were staged together, while the other archives and title DLLs were in a separate configured game_dir. run.rs mounts G: from the executable's parent. The launches therefore used an incomplete G: layout. These runs cannot establish startup or rendering behavior with the full package.
Retested with the title executable placed beside the complete package, using the Wine binary from GE-Proton 10-34 and native vkd3d-proton/DXGI overrides. Both binaries passed the earlier startup point. The base logged frame 4096 and the PR logged at least frame 512. These are presentation counters. I did not verify an interactive world or measure gameplay FPS.
@KernelSmoker on GitHub · 2026-11-25 18:32 UTC · original
Compile check note on PR head
c30bbee(cargo check --workspace --all-targets --locked --offline --target x86_64-pc-windows-gnu, Rust 1.98.1):victory-gputest compilation fails with one typo incrates/victory-gpu/src/texture/gpu_detile.rs:The non-test library and
victorybinary compile fine; this affects--all-targets/cargo test -p victory-gpu.@adrianmjim on GitHub · 2026-11-25 18:57 UTC · original
Following up on KernelSmoker's compile note above (
read_back_buffer), with the test results once that line is fixed. RX 7900 XT, Windows 11 build 26300, Rust 1.98.1 (MSVC), headc30bbee, separate target dir; the game was not run.With the line changed locally to
let (back, _) = host.readback_buffer(total).unwrap();(the method returns(ID3D12Resource, *const u8)):gpu_detiling_matches_the_cpu_texture_uploadpasses on this card, and so do the existingtexture::andindirect::tests.victory-hledstoragetests pass, including the two new ones, and so does the newtranslatetest inapps/victory.The single-record clamp is behind
VICTORY_INDIRECT_SINGLE=1, and thebound()tests use 64 to 5000 records, so no test in the suite reachesmake_single. I added a local test that clamps one record with both the 64-lane and the 1-lane shader. The output records and the budget were identical in four cases: a draw, an indexed draw with clamped instances, a dispatch above 65,535 groups, and records past the budget.indirect.rsconflicts with #120, which works on the same per-record clamp cost by batching clamps into 64-lane dispatches.On dropping
!crate::host::late(): on current main (000ffdd),execute_innerdrains the previous in-flight submission beforerun_deferred. Sofillshould not overwrite the upload buffer while an earlier prelude still reads it. I checked this only by reading the code.Not tested: FPS, the ignored benchmark, the detile path through a real submission with
VICTORY_GPU_DETILE=1, NVIDIA.View command line instructions
Checkout
From your project repository, check out a new branch and test the changes.Merge
Merge the changes and update on Forgejo.