AMD's Windows driver compiles pipelines differently when
VK_EXT_graphics_pipeline_library is enabled on the device, but its
on-disk cache (%LOCALAPPDATA%\AMD\VkCache) does not key on it. A process
in one mode is then served pipelines compiled in the other, and their
writes never land (boykopovar#4768, boykopovar#5271).
With the library feature off, every module now flips bit 15 of the SPIR-V
generator word, which no driver interprets, so the two modes hash to
separate cache entries.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
What
Fixes #4768. AMD's Windows Vulkan driver can reuse a cached pipeline compiled with the opposite
VK_EXT_graphics_pipeline_librarydevice-feature mode. In that case, shader writes may not land. When the feature is disabled, change bit 15 of the SPIR-V generator word before creating each shader module. Vulkan ignores that word, while the driver's on-disk cache hashes the changed module separately. Apply this to recompiled and embedded modules so all AGC shader paths use distinct cache keys.Tested
agc_shader_memory_testsandagc_driver_alpha_to_coverage_testscompile;agc_shader_memory_testspasses (ANYPS5_NO_SHADER_CACHE=1).python3 tools/check_conventions.py --base upstream/main --head HEAD: passed.git diff upstream/main...HEAD --check: passed.Checklist