GPU: Add mesh-to-compute fallback for RDNA1 #20
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/20"
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?
Imported from avatarmanz/VIctory-7900XTX. Originally posted by Abdellah-Khanani on 2026-11-25T23:38:55Z.
What this does
Adds a mesh-to-compute path for D3D12 adapters without native mesh shaders, aimed at RDNA1 GPUs such as the Radeon RX 5700 XT. The translator emits the mesh program as compute plus a vertex shader, and the host submits generated geometry through an indirect draw. The fallback uses a dedicated compute root signature and list-owned scratch buffers.
Also declares wave64 for the fallback, keeps mesh output limits intact for compute lowering, applies the host blend-state workaround for integer render targets, and makes the fallback scratch-pool limits configurable.
Local validation
cargo build --locked --profile diag -p victory --features diagnosticssucceeds.0x80004005). The Windows D3D12 debug layer is unavailable on this machine, so the offending command is not identified yet.This is published as a draft because the first actual gameplay scene is not verified yet.
Imported from avatarmanz/VIctory-7900XTX. Originally posted by delacor on 2026-11-27T12:05:39Z.
Linux/RDNA1 progress update from our local integration on an RX 5500 XT 8 GiB with Wine/vkd3d-proton: the opening 3D room and character geometry are now visible using the compute fallback plus additional fixes. Face/shading artifacts and dropped passes remain, so this is not an end-to-end rendering correctness claim.
Our backend accepts the state-changing indirect signatures but produces no mesh work with device-generated commands disabled. Explicit output bindings and ordinary indirect compute/draw pairs restore geometry, with each pair finishing its read before output reuse. Five actual GPU regressions pass, including multiple records whose combined storage exceeds one region. Native mesh execution keeps its existing path.
We also tested an opt-in shared Data output allocator across host lists on the single DIRECT queue. Indirect command buffers stay private; group counts, layout, capacity and write/read dependencies are preserved. Earlier size allocations remain owned after growth. The existing pool already recycles output after each draw; this addresses retention across simultaneously live lists.
The application mesh-storage counter includes command buffers and free/delayed storage; it is not total GPU memory. Warm samples cover 120–410 seconds with no shader compilation (53 private, 51 shared samples). Draw counts differ (1114.42 versus 1104.31 on average), and the shared run had USB/dock hotplug messages. This supports about 95% lower final retained mesh storage, not an established FPS gain. Neither run reported an amdgpu fault/reset.
The shared-storage GPU regression records 32 lists before submission and checks reverse batched order, separate submissions, growth and exact producer/consumer output across 64 lists. It passes and retains 3 MiB in the synthetic case. Barrier/image and indirect regressions, Windows all-target checks and the app build also pass in the integration. Other GPUs, native Windows drivers and long-session behavior remain unverified.
Credit: yoraudev's alternative Marvisak #1648 already uses global intermediate storage. Our experiment adapts that idea to this fallback allocator and translator rather than introducing another emulation implementation. Its benefit is not intrinsically limited to 8-GiB GPUs, but native mesh draws bypass these buffers. No native-path 7900 XTX speedup is claimed.
These are local integration results with follow-up changes, not validation of this PR's unmodified head. The narrow follow-up patches still need extraction against the agreed fallback base; unrelated experiments and private captures/shaders/executables will be excluded. AI-assisted investigation and synthetic regression work with Codex.
Coordinating the same follow-up with Marvisak #961. This does not change the fallback dependency or establish an improvement on the native 7900 path.
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.Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.