Skip to content

tests: keep d3d12_vulkan_device_test running on Windows 10 (TEST-97) - #717

Merged
ItsNotRexed merged 1 commit into
ItsNotRexed:mainfrom
dea7hsmiless:fix/test97-win10-host-skips
Nov 22, 2026
Merged

ItsNotRexed merged 1 commit into
ItsNotRexed:mainfrom
dea7hsmiless:fix/test97-win10-host-skips

Conversation

@dea7hsmiless

@dea7hsmiless dea7hsmiless commented Nov 22, 2026 •

Copy link
Copy Markdown
Contributor

Claimed in the coordination issue as: TEST-97 (#634 (comment))

What and why

On Windows 10 the host D3D12 runtime fails two comparisons near the start of d3d12_vulkan_device_test, and EXPECT returns on the first failure. Everything after them (command objects, clears, copies, resolve, reserved resources, descriptors) never ran, so a Windows 10 failure hid whether a PR's own new checks pass.

  • Unaligned BC footprints. GetCopyableFootprints returns -1 for every field of the 10x6 BC1 case when the host has no D3D12_OPTIONS8.UnalignedBlockTexturesSupported. The comparison now skips block-compressed cases whose top mip is not a whole number of 4x4 blocks when the host reports the option missing or does not answer the query. Aligned BC cases still compare. A small self-check covers the classification on every host.
  • Resolve regions. ResolveSubresourceRegion needs ID3D12GraphicsCommandList7, which the Windows 10 host list does not expose. The comparison now checks the host once and, without list7, compares only the full ResolveSubresource form instead of failing inside capture_resolve. The full form still covers every supported format and sample count; the two region forms are skipped with the existing skip accounting and a printed note.

Test-only change in runtime/test/d3d12_vulkan_device_test.cpp; no runtime or translator change. No game files.

Tested

Windows 11 Pro 26300, NVIDIA GeForce RTX 3070, driver 621.24, MSVC 19.44, Vulkan SDK 1.4.363.0, RelWithDebInfo (Ninja).

  • scripts\build_runtime.ps1: clean, no warnings.
  • d3d12_vulkan_device_test with LEONIDA_VK_VALIDATION=1: exit 0; Resolve comparison: 60 compared, 60 matched, 10 unsupported or host-unavailable cases skipped, 0 mismatches; GetCopyableFootprints and the later clear/copy/resolved/reserved-resource/descriptor checks all matched. Zero validation errors or VUIDs.
  • ctest --test-dir runtime/build: 29/29 passed (the test is registered with CTest on current main).

The Windows 10 branches themselves need a Windows 10 host to exercise (this machine has both the option and list7). To check them anyway, I temporarily forced host_supports_unaligned_block_textures and host_has_graphics_command_list7 to false on the same machine and reran:

GetCopyableFootprints: 1 unaligned block-compressed cases skipped (the host runtime has no D3D12_OPTIONS8.UnalignedBlockTexturesSupported)
Resolve comparison: the host runtime has no ID3D12GraphicsCommandList7; ResolveSubresourceRegion cases are skipped
Resolve comparison: 15 compared, 15 matched, 55 unsupported or host-unavailable cases skipped, 0 mismatches

Exit 0, no VUIDs, and the later checks all ran. Then I restored the real checks and rebuilt. A real Windows 10 confirmation is still welcome; the expected output is those two skip notes followed by the later checks.

AI-assisted (OpenCode, DeepSeek V4.1 Flash).

Checklist

  • 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 applicable: test-only change.)

@dea7hsmiless

Copy link
Copy Markdown
Contributor Author

Two notes from testing.

The check failure is not this PR. It is main's missing third_party/rpf9-explorer bump (ArchiveEntry.ResourceDrawableOffset, CS1061 at Program.cs:124/147); #713 re-pins it. My local dotnet build tools/rpf9dump/rpf9dump.csproj -c Release fails the same way on main. I will merge/re-run once #713 lands.

The Windows 10 branches were exercised by simulation. On the same Windows 11 / RTX 3070 machine I temporarily forced host_supports_unaligned_block_textures and host_has_graphics_command_list7 to return false, rebuilt, and ran with LEONIDA_VK_VALIDATION=1:

GetCopyableFootprints: 1 unaligned block-compressed cases skipped (the host runtime has no D3D12_OPTIONS8.UnalignedBlockTexturesSupported)
Resolve comparison: the host runtime has no ID3D12GraphicsCommandList7; ResolveSubresourceRegion cases are skipped
Resolve comparison: 15 compared, 15 matched, 40 unsupported or host-unavailable cases skipped, 0 mismatches

Exit 0, no VUIDs, and the later clear/copy/resolved/reserved-resource/descriptor checks all ran and matched. Then I restored the capability checks and rebuilt: 45 compared, 45 matched, exit 0. So the skips do what the Windows 10 finding needs; only a real Windows 10 host can confirm the host queries return false there.

Windows 10's host D3D12 runtime cannot answer unaligned block-compressed GetCopyableFootprints cases (no D3D12_OPTIONS8.UnalignedBlockTexturesSupported) and has no ID3D12GraphicsCommandList7 for ResolveSubresourceRegion. Both comparisons failed before the device checks, so a Windows 10 run stopped at line 1061/1080.

Skip unaligned BC footprint cases when the host lacks the option, and compare only the full ResolveSubresource form when the host list has no list7. The full form still covers every supported format and sample count, and a self-check covers the classification used by the footprint skip.
@Derpbeat

Copy link
Copy Markdown
Contributor

Tested 2e23f95 on Windows 10 Home 22H2 (19045), NVIDIA GeForce RTX 4090 (driver 617.14, Vulkan 1.4.351), MSVC 19.39, Windows SDK 10.0.26100, Vulkan SDK 1.4.363.0, Ninja RelWithDebInfo, LEONIDA_VK_VALIDATION=1, with no local changes: pass. This fixes TEST-97 on the machine it was found on. Thanks for picking it up.

  • d3d12_vulkan_device_test: exit 0, all the way to its last line (... GetCopyableFootprints and GetResourceTiling all matched), 0 validation messages. The new skips report:
    • GetCopyableFootprints: 1 unaligned block-compressed cases skipped (the host runtime has no D3D12_OPTIONS8.UnalignedBlockTexturesSupported)
    • Resolve comparison: the host runtime has no ID3D12GraphicsCommandList7; ResolveSubresourceRegion cases are skipped
    • Resolve comparison: 15 compared, 15 matched, 55 unsupported or host-unavailable cases skipped, 0 mismatches
  • ctest: 29/29 with validation, including d3d12_vulkan_device, which fails on this machine without the PR.
  • Control: with the test file put back to main (67204bf), the same build stops at line 1124: footprint_mismatches <= 0, as reported in TEST-97.

Code read: the skips are narrow. Only BC cases with an unaligned top mip, only when the host lacks OPTIONS8, and only the region resolve forms without CommandList7, with full resolves still compared. The classification self-check is a nice touch.

Heads-up for #706 (D3D-91): I also merged #706 into this locally. Its new FORMAT_INFO comparison is another Windows-10-only stop that this PR doesn't cover: format 191 (A4B4G4R4_UNORM) is unknown to the Windows 10 runtime (E_INVALIDARG), while the layer answers 1 plane as Windows 11 does. With both PRs the test stops at compare_format_info instead. Details are on #706. #706 also conflicts with this PR (and with main) in create_host_device, so whichever lands second needs a rebase. Not a blocker for this PR.

AI-assisted (Claude Code); repository tests only, no game files.

@dea7hsmiless

Copy link
Copy Markdown
Contributor Author

Rebased on 67204bf and re-ran CI (head 2e23f95):

Local rerun on the rebased base: 60 compared, 60 matched, 0 mismatches with validation, and ctest 29/29. This should be fully green once #713 lands; I will refresh and confirm.

@etcetera-yt

Copy link
Copy Markdown
Contributor

Windows 10 test run of TEST-97: passes.

  • Windows 10 Home 10.0.19045, NVIDIA GeForce RTX 5060 Ti, driver 621.14, MSVC 19.44, Windows SDK 10.0.26100, Vulkan SDK 1.4.363
  • PR head 2e23f95 (on main 67204bf), RelWithDebInfo, ctest -R ^d3d12_vulkan_device$: Passed (4.1 s)
  • Before, on main 67204bf: fails at EXPECT(footprint_mismatches <= 0) (line 1124); the host returns -1 for every field of the BC1 footprint case
  • With the PR, both Windows 10 branches run:
    • GetCopyableFootprints: 1 unaligned block-compressed cases skipped (the host runtime has no D3D12_OPTIONS8.UnalignedBlockTexturesSupported)
    • Resolve comparison: the host runtime has no ID3D12GraphicsCommandList7; ResolveSubresourceRegion cases are skipped, then 15 compared, 15 matched, 55 unsupported or host-unavailable cases skipped, 0 mismatches
  • The checks after them (tiling, MSAA quality, Write/ReadFromSubresource and the rest) now run and pass.

No game files. AI-assisted (Claude Code).

@Proudnoob4

Copy link
Copy Markdown
Contributor

Both Windows 10 branches confirmed on a Windows 10 host (22H2 19045, RTX 4080, NVIDIA 621.01, main 8df277f): GetCopyableFootprints: 1 unaligned block-compressed cases skipped, and Resolve comparison: the host runtime has no ID3D12GraphicsCommandList7; ResolveSubresourceRegion cases are skipped with 15 compared, 15 matched, 0 mismatches. (The test's one remaining Windows 10 failure, the shader model / root signature comparison from #704, is #816.) AI-assisted.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants