From f9688f637884a8f041ca17e857d664abe4a924b8 Mon Sep 17 00:00:00 2001 From: Mike Blumenkrantz Date: Thu, 11 May 2023 10:21:18 -0400 Subject: [PATCH] vtn: add more info to bitcast bit size error message Reviewed-by: Caio Oliveira Part-of: --- src/compiler/spirv/vtn_alu.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/compiler/spirv/vtn_alu.c b/src/compiler/spirv/vtn_alu.c index 7a5708c..7048149 100644 --- a/src/compiler/spirv/vtn_alu.c +++ b/src/compiler/spirv/vtn_alu.c @@ -1301,8 +1301,8 @@ vtn_handle_bitcast(struct vtn_builder *b, const uint32_t *w, unsigned count) vtn_fail_if(src->num_components * src->bit_size != glsl_get_vector_elements(type->type) * glsl_get_bit_size(type->type), - "Source and destination of OpBitcast must have the same " - "total number of bits"); + "Source (%%%u) and destination (%%%u) of OpBitcast must have the same " + "total number of bits", w[3], w[2]); nir_ssa_def *val = nir_bitcast_vector(&b->nb, src, glsl_get_bit_size(type->type)); vtn_push_nir_ssa(b, w[2], val); -- 2.7.4