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

Closed
opened 2026-11-26 20:18:34 +01:00 by 4ld0 · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/ubiquitarianism/leonida/pull/602
Author: @Mumogg
Created: 11/24/2026
Status: ❌ Closed

Base: main ← Head: a8-dimensions


📝 Commits (3)

  • 2e4beef d3d12: A8_UNORM render targets through VK_FORMAT_A8_UNORM_KHR (VK_KHR_maintenance5)
  • 49b750a d3d12: an A8 render target's castable list takes its own format and refuses the others
  • 348dff3 d3d12: A8_UNORM textures in 1D and 3D, as the host makes them

📊 Changes

12 files changed (+562 additions, -24 deletions)

View changed files

📝 docs/d3d12_vulkan.md (+10 -2)
📝 runtime/CMakeLists.txt (+7 -0)
📝 runtime/shims/d3d12_com.h (+3 -0)
📝 runtime/shims/d3d12_vulkan_device.cpp (+80 -13)
📝 runtime/src/gfx10_descriptors.h (+4 -0)
📝 runtime/src/vulkan_replay.h (+8 -1)
➕ runtime/test/d3d12_a8_dimensions_test.cpp (+233 -0)
📝 runtime/test/d3d12_clear_formats_test.cpp (+2 -0)
📝 runtime/test/d3d12_descriptor_test.cpp (+53 -7)
📝 runtime/test/d3d12_draw_test.cpp (+113 -0)
📝 runtime/test/gfx10_descriptors_test.cpp (+20 -1)
📝 runtime/test/vk_test_device.h (+29 -0)

📄 Description

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


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/ubiquitarianism/leonida/pull/602 **Author:** [@Mumogg](https://github.com/Mumogg) **Created:** 11/24/2026 **Status:** ❌ Closed **Base:** `main` ← **Head:** `a8-dimensions` --- ### 📝 Commits (3) - [`2e4beef`](https://github.com/ubiquitarianism/leonida/commit/2e4beefdc25e723b2eca9fde154fb0572b38f6ce) d3d12: A8_UNORM render targets through VK_FORMAT_A8_UNORM_KHR (VK_KHR_maintenance5) - [`49b750a`](https://github.com/ubiquitarianism/leonida/commit/49b750a950409529412d67cb79823e2a4373bc41) d3d12: an A8 render target's castable list takes its own format and refuses the others - [`348dff3`](https://github.com/ubiquitarianism/leonida/commit/348dff3d3555dcaee7d7ee524cf84bc18cffddea) d3d12: A8_UNORM textures in 1D and 3D, as the host makes them ### 📊 Changes **12 files changed** (+562 additions, -24 deletions) <details> <summary>View changed files</summary> 📝 `docs/d3d12_vulkan.md` (+10 -2) 📝 `runtime/CMakeLists.txt` (+7 -0) 📝 `runtime/shims/d3d12_com.h` (+3 -0) 📝 `runtime/shims/d3d12_vulkan_device.cpp` (+80 -13) 📝 `runtime/src/gfx10_descriptors.h` (+4 -0) 📝 `runtime/src/vulkan_replay.h` (+8 -1) ➕ `runtime/test/d3d12_a8_dimensions_test.cpp` (+233 -0) 📝 `runtime/test/d3d12_clear_formats_test.cpp` (+2 -0) 📝 `runtime/test/d3d12_descriptor_test.cpp` (+53 -7) 📝 `runtime/test/d3d12_draw_test.cpp` (+113 -0) 📝 `runtime/test/gfx10_descriptors_test.cpp` (+20 -1) 📝 `runtime/test/vk_test_device.h` (+29 -0) </details> ### 📄 Description 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 --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
4ld0 2026-11-26 20:18:34 +01:00
Sign in to join this conversation.
No labels
bug
pull-request
No milestone
No project
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.

Dependencies

No dependencies set

Reference
starred/leonida#644
No description provided.