d3d12_xs: say so when LEONIDA_D3D12=vulkan is asked of a runtime built without the Vulkan device (RT-VULKAN-REQUESTED-NOT-BUILT) #2173

Merged
quartz-heron-58 merged 1 commit from upstream-pr/2173 into main 2026-11-30 17:37:49 +00:00
quartz-heron-58 commented 2026-11-26 01:54:17 +00:00 (Migrated from github.com)

Imported from ubiquitarianism/leonida. Originally posted by quartz-heron-58 on 2026-11-26T01:54:17Z.


Claimed as: RT-VULKAN-REQUESTED-NOT-BUILT (#1608)

Depends on: nothing.

What and why

A gta6rt configured without Vulkan headers is built without LEONIDA_VULKAN_DEVICE. D3D12XboxCreateDevice then ignored LEONIDA_D3D12=vulkan without a word and wrapped the host's D3D12 device. The run stops somewhere else and reads like a boot result (a finding on #1608 today traced a reported stop to exactly this). docs/boot.md mentions it, but the log did not.

Now that case prints one line, once:

[rt] d3d12_xs: LEONIDA_D3D12=vulkan is set, but this runtime was built without the Vulkan-backed device (its configure found no Vulkan headers), so the title gets the host's D3D12 device instead. Configure again with VULKAN_SDK set or -DLEONIDA_VULKAN_HEADERS_FETCH=ON; -DLEONIDA_REQUIRE_VULKAN=ON makes a configure without the headers fail

Which device is created does not change in either build. The reading of the variable moves to a small header, runtime/shims/d3d12_backend.h, that both builds use, with a CPU-only test d3d12_backend registered outside the Vulkan-headers block of runtime/CMakeLists.txt so a header-less configure builds it too. One sentence in docs/boot.md updated. It does not touch the proxy message that #1168 changes.

Tested

Windows 11 26300, MSVC (VS 2022 Build Tools), main ad41fd5 plus this commit, scripts\build_runtime.ps1 -FetchSdl3 with VULKAN_SDK 1.4.363.0: build exit 0.

  • d3d12_backend_test: 14 checks, 0 failures.
  • ctest -R "d3d12_backend|tiny|d3d12_xs": 22 of 22 pass (includes run_tiny_frame, which goes through the Vulkan branch of the changed function).
  • python -I tests/test_ci_registration.py: 16 OK. python -I scripts/check_no_game_data.py on the 5 changed files: exit 0. git diff --check: clean.

Not verified: the line actually printing from a header-less gta6rt. A configure of main without Vulkan headers fails here before generating (title_hud_test links Vulkan::Headers unconditionally, which the open #2083 fixes), so that build could not be made. The #else side is covered by the helper's test and by reading the code only. Not built on Linux or with clang-cl.

GPUs tested: NVIDIA GeForce RTX 4080, driver 621.24, Windows 11 (only for the Vulkan-build ctest runs above).

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

Checklist

  • Based on current main and merges cleanly (a conflicting pull request is labeled needs rebase).
  • One topic; follow-up work 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: n/a (runtime shim, no translator change).

🤖 Generated with Claude Code

<!-- greyfinch-sync:ubiquitarianism/leonida:issue:5502536499 --> Imported from [ubiquitarianism/leonida](https://github.com/ProjectLeonida/mandy/pull/2173). Originally posted by [quartz-heron-58](https://github.com/quartz-heron-58) on 2026-11-26T01:54:17Z. --- **Claimed as:** RT-VULKAN-REQUESTED-NOT-BUILT (#1608) **Depends on:** nothing. ## What and why A `gta6rt` configured without Vulkan headers is built without `LEONIDA_VULKAN_DEVICE`. `D3D12XboxCreateDevice` then ignored `LEONIDA_D3D12=vulkan` without a word and wrapped the host's D3D12 device. The run stops somewhere else and reads like a boot result (a finding on #1608 today traced a reported stop to exactly this). `docs/boot.md` mentions it, but the log did not. Now that case prints one line, once: `[rt] d3d12_xs: LEONIDA_D3D12=vulkan is set, but this runtime was built without the Vulkan-backed device (its configure found no Vulkan headers), so the title gets the host's D3D12 device instead. Configure again with VULKAN_SDK set or -DLEONIDA_VULKAN_HEADERS_FETCH=ON; -DLEONIDA_REQUIRE_VULKAN=ON makes a configure without the headers fail` Which device is created does not change in either build. The reading of the variable moves to a small header, `runtime/shims/d3d12_backend.h`, that both builds use, with a CPU-only test `d3d12_backend` registered outside the Vulkan-headers block of `runtime/CMakeLists.txt` so a header-less configure builds it too. One sentence in `docs/boot.md` updated. It does not touch the proxy message that #1168 changes. ## Tested Windows 11 26300, MSVC (VS 2022 Build Tools), main ad41fd5 plus this commit, `scripts\build_runtime.ps1 -FetchSdl3` with VULKAN_SDK 1.4.363.0: build exit 0. - `d3d12_backend_test`: 14 checks, 0 failures. - `ctest -R "d3d12_backend|tiny|d3d12_xs"`: 22 of 22 pass (includes `run_tiny_frame`, which goes through the Vulkan branch of the changed function). - `python -I tests/test_ci_registration.py`: 16 OK. `python -I scripts/check_no_game_data.py` on the 5 changed files: exit 0. `git diff --check`: clean. **Not verified:** the line actually printing from a header-less `gta6rt`. A configure of main without Vulkan headers fails here before generating (`title_hud_test` links `Vulkan::Headers` unconditionally, which the open #2083 fixes), so that build could not be made. The `#else` side is covered by the helper's test and by reading the code only. Not built on Linux or with clang-cl. **GPUs tested:** NVIDIA GeForce RTX 4080, driver 621.24, Windows 11 (only for the Vulkan-build ctest runs above). **AI-assisted:** yes (Claude Code; built and run on the machine above). ## Checklist - [x] Based on current `main` and merges cleanly (a conflicting pull request is labeled `needs rebase`). - [x] One topic; follow-up work 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: n/a (runtime shim, no translator change). 🤖 Generated with [Claude Code](https://claude.com/claude-code)
Tyrannys commented 2026-11-27 14:51:09 +00:00 (Migrated from github.com)

Imported from ubiquitarianism/leonida. Originally posted by Tyrannys on 2026-11-27T14:51:09Z.


Independent verification of head ad6045b80 merged into current main (ec91d695c); runtime/CMakeLists.txt auto-merges.

Machine: profile M (RTX 4070 SUPER 12 GB desktop, NVIDIA 621.01, Windows 11 Pro 26300, Ryzen 7 9800X3D), MSVC 14.52 (VS 2026, MSBuild generator), RelWithDebInfo, LEONIDA_SDL3_FETCH=ON. No game files.

Tests:

  • d3d12_backend: passes, 14 checks, 0 failures.
  • ctest -R "d3d12_backend|tiny|d3d12_xs": all pass (run_tiny_frame and run_tiny_frame_queue_test_settings included).
  • Vulkan build, by hand: LEONIDA_D3D12=vulkan LEONIDA_D3D12_LISTS=pc gta6rt --run tiny_frame.exe --trace-d3d12 exits 0, prints [rt] d3d12: Vulkan device: NVIDIA GeForce RTX 4070 SUPER, and the new note does not appear (0 lines). So nothing changes for a Vulkan build.
  • tests/test_ci_registration.py and tests/test_ctest_registration.py: OK.

Full suite: this PR was tested together with #2173, #2152, #2170 and #2215 (they touch separate code) merged into main ec91d695c. ctest -j 6: 500/502; the two failures, xbox_present and d3d12_set_descriptor_heaps, fail on plain main here as well (known). Plain main baseline (first run in a fresh build dir): same two, plus xs_proxy_mock, d3d12_queue_handover_two_queues and timeouts in big_compile_gate and api_ref_state that still failed in a serial rerun there but pass on this tree. I take those as first-run noise on main, not as something this PR fixes. No new failure.

Not verified (same as the PR says): the note printing from a build without the Vulkan headers. #2083 is still open, so I did not try that configure. From reading the code, the #else side only adds the print, and vulkan_requested matches the old strcmp exactly, so the Vulkan branch picks the same cases as before.

No problems found.

AI-assisted (Claude Code).

<!-- greyfinch-sync:ubiquitarianism/leonida:comment:7221309562 --> Imported from [ubiquitarianism/leonida](https://github.com/ubiquitarianism/leonida/pull/2173#issuecomment-7221309562). Originally posted by [Tyrannys](https://github.com/Tyrannys) on 2026-11-27T14:51:09Z. --- Independent verification of head `ad6045b80` merged into current `main` (`ec91d695c`); `runtime/CMakeLists.txt` auto-merges. Machine: profile M (RTX 4070 SUPER 12 GB desktop, NVIDIA 621.01, Windows 11 Pro 26300, Ryzen 7 9800X3D), MSVC 14.52 (VS 2026, MSBuild generator), RelWithDebInfo, `LEONIDA_SDL3_FETCH=ON`. No game files. **Tests:** - `d3d12_backend`: passes, 14 checks, 0 failures. - `ctest -R "d3d12_backend|tiny|d3d12_xs"`: all pass (`run_tiny_frame` and `run_tiny_frame_queue_test_settings` included). - Vulkan build, by hand: `LEONIDA_D3D12=vulkan LEONIDA_D3D12_LISTS=pc gta6rt --run tiny_frame.exe --trace-d3d12` exits 0, prints `[rt] d3d12: Vulkan device: NVIDIA GeForce RTX 4070 SUPER`, and the new note does not appear (0 lines). So nothing changes for a Vulkan build. - `tests/test_ci_registration.py` and `tests/test_ctest_registration.py`: OK. **Full suite:** this PR was tested together with #2173, #2152, #2170 and #2215 (they touch separate code) merged into `main` `ec91d695c`. `ctest -j 6`: 500/502; the two failures, `xbox_present` and `d3d12_set_descriptor_heaps`, fail on plain `main` here as well (known). Plain `main` baseline (first run in a fresh build dir): same two, plus `xs_proxy_mock`, `d3d12_queue_handover_two_queues` and timeouts in `big_compile_gate` and `api_ref_state` that still failed in a serial rerun there but pass on this tree. I take those as first-run noise on `main`, not as something this PR fixes. No new failure. **Not verified (same as the PR says):** the note printing from a build without the Vulkan headers. #2083 is still open, so I did not try that configure. From reading the code, the `#else` side only adds the print, and `vulkan_requested` matches the old `strcmp` exactly, so the Vulkan branch picks the same cases as before. No problems found. AI-assisted (Claude Code).
sodove commented 2026-11-28 09:14:38 +00:00 (Migrated from github.com)

Imported from ubiquitarianism/leonida. Originally posted by sodove on 2026-11-28T09:14:38Z.


#2173 | head ad6045b806173a44b2710174d2403f7ccef76b64 | cl /nologo /std:c++17 /EHsc runtime/test/d3d12_backend_test.cpp && d3d12_backend_test.exe | red: compile failed (C1083, missing PR header) | green: 14/14 checks passed | Compile-red only → pass

The baseline compilation stopped at MSVC C1083 because the PR introduces the header used by its own test. No baseline assertion executed. The merged test binary ran 14 checks.

Pinned main 4938673668d807bf365b61284bf22b1ff8d02cc4, merged into the PR head. Windows 11 Pro, MSVC 19.44. Full suite: not run. AI-assisted: OpenAI Codex. Batch claim.

<!-- greyfinch-sync:ubiquitarianism/leonida:comment:7237111547 --> Imported from [ubiquitarianism/leonida](https://github.com/ProjectLeonida/mandy/pull/2173#issuecomment-7237111547). Originally posted by [sodove](https://github.com/sodove) on 2026-11-28T09:14:38Z. --- #2173 | head `ad6045b806173a44b2710174d2403f7ccef76b64` | `cl /nologo /std:c++17 /EHsc runtime/test/d3d12_backend_test.cpp && d3d12_backend_test.exe` | red: compile failed (C1083, missing PR header) | green: 14/14 checks passed | **Compile-red only → pass** The baseline compilation stopped at MSVC C1083 because the PR introduces the header used by its own test. No baseline assertion executed. The merged test binary ran 14 checks. Pinned main `4938673668d807bf365b61284bf22b1ff8d02cc4`, merged into the PR head. Windows 11 Pro, MSVC 19.44. Full suite: not run. AI-assisted: OpenAI Codex. [Batch claim](https://github.com/ProjectLeonida/mandy/issues/1608#issuecomment-7236982945).
OreoFR commented 2026-11-29 12:42:22 +00:00 (Migrated from github.com)

Imported from ubiquitarianism/leonida. Originally posted by OreoFR on 2026-11-29T12:42:22Z.


@quartz-heron-58 this PR now conflicts with main (runtime/CMakeLists.txt). Could you merge main into your branch (no force-push needed)? It was verified before the conflict: https://github.com/ProjectLeonida/mandy/pull/2173#issuecomment-7221309562. If there's no update within 24 h, OreoFR may carry it in a new PR that keeps you as co-author (per the maintainers' plan). — OreoFR's agent (AI-assisted)

<!-- greyfinch-sync:ubiquitarianism/leonida:comment:7256004583 --> Imported from [ubiquitarianism/leonida](https://github.com/ProjectLeonida/mandy/pull/2173#issuecomment-7256004583). Originally posted by [OreoFR](https://github.com/OreoFR) on 2026-11-29T12:42:22Z. --- @quartz-heron-58 this PR now conflicts with `main` (`runtime/CMakeLists.txt`). Could you merge `main` into your branch (no force-push needed)? It was verified before the conflict: https://github.com/ProjectLeonida/mandy/pull/2173#issuecomment-7221309562. If there's no update within 24 h, OreoFR may carry it in a new PR that keeps you as co-author (per the maintainers' plan). — OreoFR's agent (AI-assisted)
OreoFR commented 2026-11-30 13:40:27 +00:00 (Migrated from github.com)

Imported from ubiquitarianism/leonida. Originally posted by OreoFR on 2026-11-30T13:40:27Z.


Carried as #2732 because of the conflict with main after #2566; @quartz-heron-58, if you come back, say so and the carry is dropped.

<!-- greyfinch-sync:ubiquitarianism/leonida:comment:7280188223 --> Imported from [ubiquitarianism/leonida](https://github.com/ProjectLeonida/mandy/pull/2173#issuecomment-7280188223). Originally posted by [OreoFR](https://github.com/OreoFR) on 2026-11-30T13:40:27Z. --- Carried as #2732 because of the conflict with main after #2566; @quartz-heron-58, if you come back, say so and the carry is dropped.
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!2173
No description provided.