Skip to content

Keep barrier state tests compatible with newer Windows SDKs - #531

Merged
ItsNotRexed merged 1 commit into
ItsNotRexed:mainfrom
Capi360:codex/d3d12-barrier-layout-sdk
Nov 22, 2026
Merged

ItsNotRexed merged 1 commit into
ItsNotRexed:mainfrom
Capi360:codex/d3d12-barrier-layout-sdk

Conversation

@Capi360

@Capi360 Capi360 commented Nov 22, 2026 •

Copy link
Copy Markdown
Contributor

Task: TEST-74

Task claim in #374

Problem

Windows SDK 10.0.28000.0 omits D3D12_BARRIER_LAYOUT_VIDEO_QUEUE_COMMON, which makes d3d12_state_map_test.cpp fail with MSVC C2065 when the Vulkan targets are enabled. SDK 10.0.26100.0 exposes the legacy enum value. I reproduced this while validating the header-only build in #439.

Change

Use a C++20 compile-time presence check for the enum. Compare against the SDK value where it is declared, and check the legacy value of 30 where it is absent.

Validation

  • MSVC 19.44 compiled and ran d3d12_state_map_test on Windows 11 x64 with both SDK 10.0.26100.0 and SDK 10.0.28000.0.
  • With this test change applied to CI: build Windows Vulkan/COM targets via Vulkan-Headers and add sccache #439 at 35321bd, the header-only Vulkan build completed using the Visual Studio 2022 x64 CMake generator and SDK 10.0.28000.0. All 19 registered CTest entries succeeded, with package-dependent and opt-in portions skipped.
  • git diff --check passed.

CPU-only validation with synthetic fixtures. Test machine GPU: RTX 3060 Ti, NVIDIA 616.56.

AI-assisted.

Windows SDK 10.0.28000.0 omits the legacy video queue layout
enumerator. Compare against the enum when the SDK exposes it and
check the established numeric value on newer SDKs.
@Capi360

Capi360 commented Nov 22, 2026

Copy link
Copy Markdown
Contributor Author

CI baseline check for 0b29a78 on base 91b36cf:

AI-assisted CI triage.

@ItsNotRexed
ItsNotRexed merged commit 6b34635 into ItsNotRexed:main Nov 22, 2026
5 of 9 checks passed
@kacper-serewis

Copy link
Copy Markdown
Contributor

Tested 0b29a78 on RTX 5070 (Blackwell, subgroup 32..32), NVIDIA 616.56, Windows 11 Pro 26200, Windows SDK 10.0.26100.0, MSVC 19.50: pass.

  • builds cleanly with build_runtime.ps1; ctest 23/23
  • d3d12_state_map_test: "state map, enhanced barriers, subresource decoding and layout tracking OK"

@woreksami

Copy link
Copy Markdown

Tested 0b29a78 on an RTX 3060 (driver 610.88), Windows 11, Windows SDK as installed with VS 18 Build Tools: pass. Builds with the Vulkan targets on, ctest 23/23, d3d12_state_map_test passes.

Setup: Windows 11 Pro, NVIDIA GeForce RTX 3060 (Ampere), driver 610.88, Vulkan 1.4.341, MSVC (VS 18 Build Tools), Ninja, RelWithDebInfo. No validation layer installed, so not run with LEONIDA_VK_VALIDATION=1. AI-assisted (Claude Code).

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.

4 participants