From: Mike Blumenkrantz Date: Fri, 26 Jun 2020 19:14:20 +0000 (-0400) Subject: zink: add some asserts for building access chains in ntv X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=0ef5e19874ba21f268c5ffdfff0b2819056ba51a;p=mesa.git zink: add some asserts for building access chains in ntv we're never going to pass a 0 here, and it's going to be an error if we do Reviewed-by: Erik Faye-Lund Part-of: --- diff --git a/src/gallium/drivers/zink/nir_to_spirv/spirv_builder.c b/src/gallium/drivers/zink/nir_to_spirv/spirv_builder.c index 8bcad066601..530036d3d70 100644 --- a/src/gallium/drivers/zink/nir_to_spirv/spirv_builder.c +++ b/src/gallium/drivers/zink/nir_to_spirv/spirv_builder.c @@ -351,6 +351,8 @@ spirv_builder_emit_access_chain(struct spirv_builder *b, SpvId result_type, SpvId base, const SpvId indexes[], size_t num_indexes) { + assert(base); + assert(result_type); SpvId result = spirv_builder_new_id(b); int words = 4 + num_indexes;