glsl_to_nir: fix vote_any/vote_all
authorRob Clark <robdclark@chromium.org>
Wed, 17 Jun 2020 00:46:43 +0000 (17:46 -0700)
committerMarge Bot <eric+marge@anholt.net>
Thu, 18 Jun 2020 03:40:54 +0000 (03:40 +0000)
Signed-off-by: Rob Clark <robdclark@chromium.org>
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5505>

src/compiler/glsl/glsl_to_nir.cpp

index d09377b24ef3bbb9a46b1c429440ea54c0a59fff..69bcdeeff590a65a2d998bcece32715b309fc799 100644 (file)
@@ -1534,11 +1534,12 @@ nir_visitor::visit(ir_call *ir)
          nir_builder_instr_insert(&b, &instr->instr);
          break;
       }
+      case nir_intrinsic_vote_ieq:
+         instr->num_components = 1;
+         /* fall-through */
       case nir_intrinsic_vote_any:
-      case nir_intrinsic_vote_all:
-      case nir_intrinsic_vote_ieq: {
+      case nir_intrinsic_vote_all: {
          nir_ssa_dest_init(&instr->instr, &instr->dest, 1, 1, NULL);
-         instr->num_components = 1;
 
          ir_rvalue *value = (ir_rvalue *) ir->actual_parameters.get_head();
          instr->src[0] = nir_src_for_ssa(evaluate_rvalue(value));