Repository navigation
d3d12_compute_test: the CachedPSO blob's bytes no longer hide the test's bytes (C4456) - #2852
Conversation
…t's bytes (C4456) The CachedPSO block (9cc95bf) copies the cached blob into a std::vector<std::uint8_t> named bytes, which hides the test's constexpr UINT bytes = elements * 4 (line 285); MSVC reports C4456 at line 395. The vector is now blob_bytes. No behaviour change. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Code read of AI-assisted review (Claude Code). |
Kam471
left a comment
There was a problem hiding this comment.
Pure C4456 fix, verified by inspection: the cached-blob vector is renamed to blob_bytes and all six uses (the byte loop, copy, and five resealed() calls) are updated; the constexpr UINT ... bytes at line 285 is untouched, as are its uses. No behaviour change, git diff --check clean, one file +8/-8. A configured MSVC build is not present in the worktree, so I did not re-run the warning build; the diff is exactly the warning the body quotes. Approve.
|
Tested
Not tested: validation layers, clang-cl, other GPUs. Tested with AI assistance (Claude); no game files or data involved. |
|
Tested
|
|
Tested 78ea5f8 (merged onto main 77444fa) on NVIDIA GeForce RTX 4060 Ti, driver 610.88 (32.0.16.1088), Windows 11 26200, MSVC 14.51.36231 (VS 2026), Vulkan SDK 1.4.363.0: pass
AI-assisted (Claude). |
|
Thanks @Kam471 for the review, @tupacfan04 for the code read, and @iurysf, @zzEmmazz and @FaKL-Code for the test runs. AI-assisted (Claude Code). |
|
Tested 78ea5f8 merged onto main 1628210 on an RTX 5090 (driver 616.92), Windows 11, MSVC 19.44, Vulkan SDK 1.4.363, RelWithDebInfo:
AI-assisted (Claude Code). |
|
Thanks @JRamos1993 for the run on the RTX 5090. AI-assisted (Claude Code). |
Claimed in the coordination issue as: new BUILD item, MSVC C4456 in
runtime/test/d3d12_compute_test.cpp(claim)What and why
#1683 (9cc95bf) added the CachedPSO checks to
d3d12_compute_test. They copy the cached blob into a vector namedbytes, which hides the test'sconstexpr UINT elements = 64, bytes = elements * 4;(line 285). On mainec8ec4c9, MSVC prints:The vector is now
blob_bytes(8 lines, one file). Nothing else changes, so there's no change in behaviour.Nothing is left for this item. On main, the build has two other new C4996 warnings in tests,
fopenatd3d12_bundle_test.cpp:518andgetenvatd3d12_first_light_test.cpp:68; they are separate items. Thexgameruntime.cppC4201/C4996 warnings are left to #1798, per #2296.Tested
NVIDIA GeForce RTX 5060 Ti, driver 621.14, Windows 10 19045. VS 2022 Build Tools (MSVC), Vulkan SDK 1.4.363.0.
ec8ec4c978ea5f84d3d12_vulkan_devicefailsd3d12_computed3d12_vulkan_devicefails on Windows 10 with and without this PR (new format 191: the host refuses a texture the layer creates: the Windows 10 runtime has no A4B4G4R4). #2438 fixes that.Not tested: a clang-cl build, and other GPUs. The change is a rename, so there is no negative control beyond the warning itself, which main still prints.
Checklist
docs/design.md, with how it was confirmed. (n/a: no translator change)AI-assisted (Claude Code).
🤖 Generated with Claude Code