Module: Mesa Branch: main Commit: 63dc39ac9047fce206ac11b6e556b6e9a0f8a07b URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=63dc39ac9047fce206ac11b6e556b6e9a0f8a07b
Author: Mike Blumenkrantz <[email protected]> Date: Wed May 11 16:02:51 2022 -0400 zink: clamp out min_lod operands for explicit lod ops this is illegal (and nonsensical) cc: mesa-stable Reviewed-by: Dave Airlie <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16456> --- src/gallium/drivers/zink/nir_to_spirv/nir_to_spirv.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/gallium/drivers/zink/nir_to_spirv/nir_to_spirv.c b/src/gallium/drivers/zink/nir_to_spirv/nir_to_spirv.c index 8afde8f3208..2cab052c0b3 100644 --- a/src/gallium/drivers/zink/nir_to_spirv/nir_to_spirv.c +++ b/src/gallium/drivers/zink/nir_to_spirv/nir_to_spirv.c @@ -3460,6 +3460,8 @@ emit_tex(struct ntv_context *ctx, nir_tex_instr *tex) result = spirv_builder_emit_image_fetch(&ctx->builder, actual_dest_type, image, coord, lod, sample, const_offset, offset, tex->is_sparse); } else { + if (tex->op == nir_texop_txl) + min_lod = 0; result = spirv_builder_emit_image_sample(&ctx->builder, actual_dest_type, load, coord,
