d3d12: A8_UNORM textures in 1D and 3D, again; the retail frame loop then runs for minutes (RT-A8-DIMENSIONS) #602

Closed
Mumogg wants to merge 3 commits from upstream-pr/602 into main
Mumogg commented 2026-11-24 09:46:33 +00:00 (Migrated from github.com)

Imported from ubiquitarianism/leonida. Originally posted by Mumogg on 2026-11-24T09:46:33Z.


Claimed in #14 as RT-A8-DIMENSIONS. Depends on: #428 (its two commits come first here; this pull request is the last commit). Independent of my stacked proxy pull requests.

What and why

The third description that device slot 25 refuses on the retail boot (after #427's and #428's) is a 1D A8_UNORM texture, 128 x 1, no flags. main only accepts A8_UNORM in 2D, so the log says GetResourceAllocationInfo format not supported yet: 65, slot 25 answers UINT64_MAX, and a worker thread of the title stops on its int3; a few seconds later the title's crash reporting ends the process (the 30 s exit I corrected in #432).

Commit 952be9b04 by NiiRoZz (old PR 7755; -x, authorship kept; an ancestor of main whose content is not in the tree): an A8_UNORM texture is an R8_UNORM image in 1D and 3D too, as the host makes all three, with d3d12_a8_dimensions_test.

The one conflict is with #428, which the commit predates: resolved as the original integration merge (a5c96e0dd) did. A 2D render target stays VK_FORMAT_A8_UNORM_KHR; every other A8 texture, in any dimension, is R8_UNORM; a render target that is not 2D is refused. The commit message says so.

Measured

Linux (Nobara 44, kernel 7.3), Wine 11.21 staging, RTX 5070 Ti (driver 615.78.08), clang-cl 22.1.8 + xwin SDK 10.0.26100, own 1.0.2.1 copy, network off, 300 s allowed, on main ece4ba5b3 with my stacked pull requests up to #432 and #142, #219, #328, #387.

--run without this (two runs) with this
How it ends exit 3 at about 30 s: the worker thread's int3, then the title's crash reporting exit 137 at 296 s: killed by the memory cap I run it under
Title exceptions in the startup trace 2 0
Traced D3D12 calls 537,677 and 577,901 5,069,510
CreatePipelineState ok 50,466 (4 failed) 50,466 (4 failed)
ExecuteCommandLists ok 26,400 278,135, none failed
XboxPresentation::PresentX ok 13,199 and 14,316 139,067, none failed

About the end of the long run, since I got this wrong once already: I read the exit line this time. Exit 137 is a kill, and the system journal for that run says The kernel OOM killer killed some processes in this unit with a 52 GB memory peak, which is the cap I set (MemoryMax=52G). The integration branch (#321) ends the same way at about the same time; there it is the NVIDIA compiler taking the title's largest compute modules. I have not confirmed that it is the same cause here.

Still open on this path: the four rectangle-list pipelines (primitive topology type not supported: 19), queue slot 31, the memory growth, and the picture, which I have not looked at.

Tests under Wine:

Test Result
d3d12_a8_dimensions (new with the commit) passed
d3d12_descriptor passed
d3d12_draw passed

Not built with MSVC and not run on Windows.

AI-assisted (Claude Code); built and run on the machine above.

🤖 Generated with Claude Code

https://claude.ai/code/session_01HxBQf4pXH8PWpC5oZsM4bt

<!-- greyfinch-sync:ubiquitarianism/leonida:issue:5469785716 --> Imported from [ubiquitarianism/leonida](https://github.com/ubiquitarianism/leonida/pull/602). Originally posted by [Mumogg](https://github.com/Mumogg) on 2026-11-24T09:46:33Z. --- Claimed in #14 as `RT-A8-DIMENSIONS`. Depends on: #428 (its two commits come first here; this pull request is the last commit). Independent of my stacked proxy pull requests. ### What and why The third description that device slot 25 refuses on the retail boot (after #427's and #428's) is a **1D** A8_UNORM texture, 128 x 1, no flags. `main` only accepts A8_UNORM in 2D, so the log says `GetResourceAllocationInfo format not supported yet: 65`, slot 25 answers `UINT64_MAX`, and a worker thread of the title stops on its `int3`; a few seconds later the title's crash reporting ends the process (the 30 s exit I corrected in #432). Commit `952be9b04` by NiiRoZz (old PR 7755; `-x`, authorship kept; an ancestor of `main` whose content is not in the tree): an A8_UNORM texture is an R8_UNORM image in 1D and 3D too, as the host makes all three, with `d3d12_a8_dimensions_test`. The one conflict is with #428, which the commit predates: resolved as the original integration merge (`a5c96e0dd`) did. A 2D render target stays `VK_FORMAT_A8_UNORM_KHR`; every other A8 texture, in any dimension, is R8_UNORM; a render target that is not 2D is refused. The commit message says so. ### Measured Linux (Nobara 44, kernel 7.3), Wine 11.21 staging, RTX 5070 Ti (driver 615.78.08), clang-cl 22.1.8 + xwin SDK 10.0.26100, own 1.0.2.1 copy, network off, 300 s allowed, on `main` `ece4ba5b3` with my stacked pull requests up to #432 and #142, #219, #328, #387. | `--run` | without this (two runs) | with this | |---|---|---| | How it ends | exit 3 at about 30 s: the worker thread's `int3`, then the title's crash reporting | exit 137 at 296 s: killed by the memory cap I run it under | | Title exceptions in the startup trace | 2 | 0 | | Traced D3D12 calls | 537,677 and 577,901 | 5,069,510 | | `CreatePipelineState` ok | 50,466 (4 failed) | 50,466 (4 failed) | | `ExecuteCommandLists` ok | 26,400 | 278,135, none failed | | `XboxPresentation::PresentX` ok | 13,199 and 14,316 | 139,067, none failed | About the end of the long run, since I got this wrong once already: I read the exit line this time. Exit 137 is a kill, and the system journal for that run says `The kernel OOM killer killed some processes in this unit` with a 52 GB memory peak, which is the cap I set (`MemoryMax=52G`). The integration branch (#321) ends the same way at about the same time; there it is the NVIDIA compiler taking the title's largest compute modules. I have not confirmed that it is the same cause here. Still open on this path: the four rectangle-list pipelines (`primitive topology type not supported: 19`), queue slot 31, the memory growth, and **the picture, which I have not looked at**. Tests under Wine: | Test | Result | |---|---| | `d3d12_a8_dimensions` (new with the commit) | passed | | `d3d12_descriptor` | passed | | `d3d12_draw` | passed | Not built with MSVC and not run on Windows. AI-assisted (Claude Code); built and run on the machine above. 🤖 Generated with [Claude Code](https://claude.com/claude-code) https://claude.ai/code/session_01HxBQf4pXH8PWpC5oZsM4bt
Dezmonius commented 2026-11-24 13:11:33 +00:00 (Migrated from github.com)

Imported from ubiquitarianism/leonida. Originally posted by Dezmonius on 2026-11-24T13:11:33Z.


Independent Windows A/B check. Windows 10 22H2 (19045), RTX 5070 (NVIDIA 610.88), Vulkan, MSVC 19.51.36256, Windows SDK 10.0.26100 and Ninja/Release.

Synthetic test #428 only (49b750a95) #428 + #602 (348dff3d3)
d3d12_a8_dimensions Fails at the CheckFeatureSupport dimension-bit assertion (line 101) Pass
d3d12_descriptor Pass Pass
d3d12_draw Pass Pass
d3d12_clear_formats Pass Pass

The control uses the same new test source and CMake registration, with no runtime changes. With #602, both textures reported 65,536-byte allocations. All 128 (1D) and 256 (3D) texels round-tripped, and both SRVs decoded to (0, 0, 0, A). The 2D A8 render-target test exercised clear, draw and all three alpha blends on both builds.

Synthetic tests only. No game files, no retail boot and no online gameplay. AI-assisted (Codex).

<!-- greyfinch-sync:ubiquitarianism/leonida:comment:7132478827 --> Imported from [ubiquitarianism/leonida](https://github.com/ubiquitarianism/leonida/pull/602#issuecomment-7132478827). Originally posted by [Dezmonius](https://github.com/Dezmonius) on 2026-11-24T13:11:33Z. --- Independent Windows A/B check. Windows 10 22H2 (19045), RTX 5070 (NVIDIA 610.88), Vulkan, MSVC 19.51.36256, Windows SDK 10.0.26100 and Ninja/Release. | Synthetic test | #428 only (`49b750a95`) | #428 + #602 (`348dff3d3`) | | --- | --- | --- | | `d3d12_a8_dimensions` | Fails at the `CheckFeatureSupport` dimension-bit assertion (line 101) | Pass | | `d3d12_descriptor` | Pass | Pass | | `d3d12_draw` | Pass | Pass | | `d3d12_clear_formats` | Pass | Pass | The control uses the same new test source and CMake registration, with no runtime changes. With #602, both textures reported 65,536-byte allocations. All 128 (1D) and 256 (3D) texels round-tripped, and both SRVs decoded to `(0, 0, 0, A)`. The 2D A8 render-target test exercised clear, draw and all three alpha blends on both builds. Synthetic tests only. No game files, no retail boot and no online gameplay. AI-assisted (Codex).
Snooozs commented 2026-11-24 17:01:56 +00:00 (Migrated from github.com)

Imported from ubiquitarianism/leonida. Originally posted by Snooozs on 2026-11-24T17:01:56Z.


Independent check. Windows 10 Pro 22H2 (19045), VS 2022 RelWithDebInfo, Vulkan SDK 1.4.363.0, LEONIDA_VK_VALIDATION=1, merged onto main 82a2aabcc without conflicts, test targets rebuilt; RTX 5060 Ti (621.01) and a Ryzen 7 7700 iGPU (1002:164E, AMD 31.0.22044.1). On the iGPU the pipeline tests fail on plain main too (128 push-constant bytes), so they say nothing there.

  • d3d12_a8_dimensions_test: PASS on both GPUs (1D 128 and 3D 256 texels round-trip, SRV reads (0, 0, 0, A)).
  • d3d12_clear_formats_test, d3d12_descriptor_test: exit 0 on both GPUs; d3d12_draw_test, gfx10_descriptors_test: exit 0 on the RTX 5060 Ti. 0 VUID lines.

Reading note: in create_vulkan_device_standalone the push of VK_KHR_MAINTENANCE_5_EXTENSION_NAME sits inside the #ifdef VK_KHR_MAINTENANCE_8_EXTENSION_NAME block. With headers that have maintenance5 but not maintenance8, the feature struct would be chained and a8_render_target set without the extension being enabled. Closing the maintenance8 block first fixes it. I did not build with such headers.

Synthetic tests only, no game files. AI-assisted (Claude Code): I read the diff and ran the tests on that machine.

<!-- greyfinch-sync:ubiquitarianism/leonida:comment:7138579591 --> Imported from [ubiquitarianism/leonida](https://github.com/ubiquitarianism/leonida/pull/602#issuecomment-7138579591). Originally posted by [Snooozs](https://github.com/Snooozs) on 2026-11-24T17:01:56Z. --- Independent check. Windows 10 Pro 22H2 (19045), VS 2022 RelWithDebInfo, Vulkan SDK 1.4.363.0, `LEONIDA_VK_VALIDATION=1`, merged onto `main` 82a2aabcc without conflicts, test targets rebuilt; RTX 5060 Ti (621.01) and a Ryzen 7 7700 iGPU (1002:164E, AMD 31.0.22044.1). On the iGPU the pipeline tests fail on plain `main` too (128 push-constant bytes), so they say nothing there. - `d3d12_a8_dimensions_test`: PASS on both GPUs (1D 128 and 3D 256 texels round-trip, SRV reads (0, 0, 0, A)). - `d3d12_clear_formats_test`, `d3d12_descriptor_test`: exit 0 on both GPUs; `d3d12_draw_test`, `gfx10_descriptors_test`: exit 0 on the RTX 5060 Ti. 0 VUID lines. Reading note: in `create_vulkan_device_standalone` the push of `VK_KHR_MAINTENANCE_5_EXTENSION_NAME` sits inside the `#ifdef VK_KHR_MAINTENANCE_8_EXTENSION_NAME` block. With headers that have maintenance5 but not maintenance8, the feature struct would be chained and `a8_render_target` set without the extension being enabled. Closing the maintenance8 block first fixes it. I did not build with such headers. Synthetic tests only, no game files. AI-assisted (Claude Code): I read the diff and ran the tests on that machine.
aslan2142 commented 2026-11-25 08:39:49 +00:00 (Migrated from github.com)

Imported from ubiquitarianism/leonida. Originally posted by aslan2142 on 2026-11-25T08:39:49Z.


Closing as carried: main makes A8_UNORM textures in 1D, 2D and 3D as R8 images and limits only render targets to 2D, since #984's integration.

  • main's own d3d12_a8_dimensions_test covers 1D, 1D arrays, 2D and 3D, with mips. That test file is most of what a line-by-line check finds missing here; the rest is comment wording.
  • Still open, and not part of this PR: Daolyap's question on #428 about A8 textures with unordered access that are not render targets.

Thanks.

AI-assisted (Claude Code, Claude Opus 5.5).

<!-- greyfinch-sync:ubiquitarianism/leonida:comment:7157316006 --> Imported from [ubiquitarianism/leonida](https://github.com/ubiquitarianism/leonida/pull/602#issuecomment-7157316006). Originally posted by [aslan2142](https://github.com/aslan2142) on 2026-11-25T08:39:49Z. --- Closing as carried: `main` makes A8_UNORM textures in 1D, 2D and 3D as R8 images and limits only render targets to 2D, since #984's integration. - `main`'s own `d3d12_a8_dimensions_test` covers 1D, 1D arrays, 2D and 3D, with mips. That test file is most of what a line-by-line check finds missing here; the rest is comment wording. - Still open, and not part of this PR: Daolyap's question on #428 about A8 textures with unordered access that are not render targets. Thanks. AI-assisted (Claude Code, Claude Opus 5.5).

Pull request closed

Sign in to join this conversation.
No reviewers
No labels
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.

Reference
ProjectLeonida/mandy!602
No description provided.