spirv: Demote the SPIRV 1.6 OpTypeSampledImage on Buffer failure to a warning.

The hangover DXVK builds we want to use for arm64 CI hit this path, and we
have a perfectly reasonable fallback for handling this case (ignore the
sampler, as glslang should have done).

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40959>
This commit is contained in:
Emma Anholt 2026-04-13 11:49:13 -07:00 committed by Marge Bot
parent a2ac64918b
commit f7d1f59948

View file

@ -1934,9 +1934,14 @@ validate_image_type_for_sampled_image(struct vtn_builder *b,
dim == GLSL_SAMPLER_DIM_SUBPASS_MS,
"%s must not have a Dim of SubpassData.", operand);
vtn_fail_if(dim == GLSL_SAMPLER_DIM_BUF && b->version >= 0x10600,
"Starting with SPIR-V 1.6, %s must not have a Dim of Buffer.",
/* While this is invalid, the glslang used by hangover's arm64 DXVK build
* (used in our CI) does hit this path for the builtin YUV conversion
* shaders.
*/
if (dim == GLSL_SAMPLER_DIM_BUF && b->version >= 0x10600) {
vtn_warn("Starting with SPIR-V 1.6, %s must not have a Dim of Buffer.",
operand);
}
}
static void