d3d12_xs: slots 127 and 133 make a depth-stencil texture without unordered access (RT-DS-UAV-SLOTS) #772

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

@⁠DesertGamer on GitHub · 2026-11-24 13:39 UTC · original
DesertGamer:fix/ds-uav-slots-127-133 → main · +2478 −131 · 23 files · 30 commits · open

Claimed in the coordination issue as: RT-DS-UAV-SLOTS (#14)

Depends on: #427. The branch is #427's head plus one commit, so the diff here also lists #427's commits until it merges; the change of this pull request is the last commit only (runtime/shims/d3d12_xs_device.cpp, runtime/test/xs_proxy_mock_test.cpp).

What and why

#427 stops a console depth-stencil texture that also allows unordered access from reaching the PC runtime with the pair (the PC runtime refuses it, and Vulkan has no depth format with storage support): such a texture is made as a depth-stencil texture alone, through pc_resource_flags / without_depth_stencil_uav, at slots 25 and 76. DadaCap measured the same description at two more resource-creating slots on a run that gets past the pipeline wall (#14): 127 and 133 (and 108, below). Both masked the Xbox bits only and kept ALLOW_UNORDERED_ACCESS on a depth-stencil texture.

  • Slot 127 (CreateCommittedResource3) takes its PC flags from pc_resource_flags. The local copy of the flag mask in d3d12_xs_device.cpp is gone; d3d12_xs_desc_clean.h has the same one.
  • Slot 133 (CreatePlacedResourceX) drops the flag on a depth-stencil texture with without_depth_stencil_uav; a buffer, a render target and a plain depth-stencil texture keep what they had.

Slot 108 (GetResourceAllocationInfo2) sizes descriptions the same way, but it is routed by #219 / #727, which this does not depend on; it follows in its own pull request once one of them is in main.

Tested

  • ctest -R "xs_proxy_mock|device_proxy": 9 of 9 pass (MSVC, Windows 11, Vulkan SDK 1.4.363). The new slot 127 checks fail with the old flag line put back (checked), so they cover the change.
  • Slot 127: a depth-stencil + unordered access description reaches the PC call as depth-stencil alone, and the title's description is not written to; a plain depth-stencil, a buffer and a render target + unordered access keep their flags. Slot 133: the same for a texture description handed to the placed-resource handler.
  • scripts/check_no_game_data.py on the two changed files: pass.
  • Not run: a retail boot on this change. The two slots are only reached past the pipeline wall DadaCap describes, which my stack has not reached.

GPUs tested: NVIDIA GeForce RTX 5070, driver 617.14, Windows 11 (unit tests only, no GPU path changed)

AI-assisted: yes (Claude Code, Sonnet 5.5)

Checklist

  • Based on current main and merges cleanly once #427 is in.
  • One topic; slot 108 goes in a new pull request.
  • No game data, keys or decryption (CONTRIBUTING.md), including in logs or reports quoted here.
  • A new translator rule is in the contract table of docs/design.md, with how it was confirmed. (Not a translator change.)
**@⁠DesertGamer** on GitHub · 2026-11-24 13:39 UTC · [original](https://github.com/ubiquitarianism/leonida/pull/772) `DesertGamer:fix/ds-uav-slots-127-133` → `main` · +2478 −131 · 23 files · 30 commits · open Claimed in the coordination issue as: RT-DS-UAV-SLOTS (https://git.gtahub.st/github/ubiquitarianism--leonida/issues/14) Depends on: #427. The branch is #427's head plus one commit, so the diff here also lists #427's commits until it merges; the change of this pull request is the last commit only (`runtime/shims/d3d12_xs_device.cpp`, `runtime/test/xs_proxy_mock_test.cpp`). ### What and why #427 stops a console depth-stencil texture that also allows unordered access from reaching the PC runtime with the pair (the PC runtime refuses it, and Vulkan has no depth format with storage support): such a texture is made as a depth-stencil texture alone, through `pc_resource_flags` / `without_depth_stencil_uav`, at slots 25 and 76. DadaCap measured the same description at two more resource-creating slots on a run that gets past the pipeline wall (https://git.gtahub.st/github/ubiquitarianism--leonida/issues/14): 127 and 133 (and 108, below). Both masked the Xbox bits only and kept `ALLOW_UNORDERED_ACCESS` on a depth-stencil texture. - Slot 127 (`CreateCommittedResource3`) takes its PC flags from `pc_resource_flags`. The local copy of the flag mask in `d3d12_xs_device.cpp` is gone; `d3d12_xs_desc_clean.h` has the same one. - Slot 133 (`CreatePlacedResourceX`) drops the flag on a depth-stencil texture with `without_depth_stencil_uav`; a buffer, a render target and a plain depth-stencil texture keep what they had. Slot 108 (`GetResourceAllocationInfo2`) sizes descriptions the same way, but it is routed by #219 / #727, which this does not depend on; it follows in its own pull request once one of them is in `main`. ### Tested - `ctest -R "xs_proxy_mock|device_proxy"`: 9 of 9 pass (MSVC, Windows 11, Vulkan SDK 1.4.363). The new slot 127 checks fail with the old flag line put back (checked), so they cover the change. - Slot 127: a depth-stencil + unordered access description reaches the PC call as depth-stencil alone, and the title's description is not written to; a plain depth-stencil, a buffer and a render target + unordered access keep their flags. Slot 133: the same for a texture description handed to the placed-resource handler. - `scripts/check_no_game_data.py` on the two changed files: pass. - Not run: a retail boot on this change. The two slots are only reached past the pipeline wall DadaCap describes, which my stack has not reached. GPUs tested: NVIDIA GeForce RTX 5070, driver 617.14, Windows 11 (unit tests only, no GPU path changed) AI-assisted: yes (Claude Code, Sonnet 5.5) ### Checklist - [x] Based on current `main` and merges cleanly once #427 is in. - [x] One topic; slot 108 goes in a new pull request. - [x] No game data, keys or decryption (CONTRIBUTING.md), including in logs or reports quoted here. - [ ] A new translator rule is in the contract table of `docs/design.md`, with how it was confirmed. (Not a translator change.)
A console depth-stencil texture may also allow unordered access, which the PC runtime refuses. Slots 25 and 76 already create such a texture as a depth-stencil texture alone; slots 127 (CreateCommittedResource3) and 133 (CreatePlacedResourceX) masked only the Xbox flag bits and kept the pair.

Slot 127 now takes its PC flags from pc_resource_flags, and slot 133 drops the flag on a depth-stencil texture with without_depth_stencil_uav. Buffers, render targets and plain depth-stencil textures keep their flags. The mock tests cover both slots.
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-26 09:20:38 +00:00
Author
Owner

@⁠MoonEyes on GitHub · 2026-11-25 17:14 UTC · original

Note for triage: this is not a duplicate of #427. It carries #427's commits plus cbdaf7ece (slots 127/133), and that part is not in main yet (slot 127/133 still keep UNORDERED_ACCESS on depth-stencil textures).

AI-assisted: yes (Claude Code compared the diffs against origin/main; I reviewed it).

**@⁠MoonEyes** on GitHub · 2026-11-25 17:14 UTC · [original](https://github.com/ubiquitarianism/leonida/pull/772#issuecomment-7169203621) Note for triage: this is not a duplicate of #427. It carries #427's commits plus cbdaf7ece (slots 127/133), and that part is not in main yet (slot 127/133 still keep UNORDERED_ACCESS on depth-stencil textures). AI-assisted: yes (Claude Code compared the diffs against origin/main; I reviewed it).
This pull request has changes conflicting with the target branch.
  • runtime/shims/d3d12_xs_device.cpp
  • runtime/test/xs_proxy_mock_test.cpp
View command line instructions

Manual merge helper

Use this merge commit message when completing the merge manually.

Checkout

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

Merge

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