From: Erik Faye-Lund Date: Thu, 19 Dec 2019 09:17:14 +0000 (+0100) Subject: zink: fixup initialization of operand_mask / num_extra_operands X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=09b37ba65f5870112a4f60f75d7e74594bdbee01;p=mesa.git zink: fixup initialization of operand_mask / num_extra_operands This doesn't change behavior, but makes the code a bit easier to read. Both values are zero, but I somehow swapped the logical meaning of them when initializing. --- 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 43a4a556653..572b38b291d 100644 --- a/src/gallium/drivers/zink/nir_to_spirv/spirv_builder.c +++ b/src/gallium/drivers/zink/nir_to_spirv/spirv_builder.c @@ -530,9 +530,9 @@ spirv_builder_emit_image_sample(struct spirv_builder *b, operands++; } - SpvImageOperandsMask operand_mask = 0; + SpvImageOperandsMask operand_mask = SpvImageOperandsMaskNone; SpvId extra_operands[4]; - int num_extra_operands = SpvImageOperandsMaskNone; + int num_extra_operands = 0; if (bias) { extra_operands[++num_extra_operands] = bias; operand_mask |= SpvImageOperandsBiasMask;