All three passes have the same bug where, in the mov/vec case they
unconditionally return true even if they don't change anything. Throw
in a bit size check so they return false properly.
Reviewed-by: Karol Herbst <kherbst@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6435>
case nir_op_ior:
case nir_op_ixor:
if (nir_dest_bit_size(alu->dest.dest) > 1)
- break; /* Not a boolean instruction */
+ return false; /* Not a boolean instruction */
/* Fallthrough */
case nir_op_ball_fequal2:
case nir_op_vec4:
case nir_op_vec8:
case nir_op_vec16:
+ if (alu->dest.dest.ssa.bit_size != 1)
+ return false;
/* These we expect to have booleans but the opcode doesn't change */
break;
case nir_op_iand:
case nir_op_ior:
case nir_op_ixor:
+ if (alu->dest.dest.ssa.bit_size != 1)
+ return false;
/* These we expect to have booleans but the opcode doesn't change */
break;