summaryrefslogtreecommitdiffstats
path: root/src/compiler
diff options
context:
space:
mode:
authorJason Ekstrand <[email protected]>2020-03-30 12:09:03 -0500
committerMarge Bot <[email protected]>2020-03-31 00:18:05 +0000
commitc26bf848ba7c5474ac99ffbe942021d8841e53ed (patch)
tree661e37255c47875eb969ac8984948abc46dadbf6 /src/compiler
parent99540edfde8576b751f96ae0c686ea6300c8a5ec (diff)
nir: Handle vec8/16 in opt_undef_vecN
Reviewed-by: Alyssa Rosenzweig <[email protected]> Reviewed-by: Ian Romanick <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4365>
Diffstat (limited to 'src/compiler')
-rw-r--r--src/compiler/nir/nir_opt_undef.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/src/compiler/nir/nir_opt_undef.c b/src/compiler/nir/nir_opt_undef.c
index 1f939e82c68..6342377ba62 100644
--- a/src/compiler/nir/nir_opt_undef.c
+++ b/src/compiler/nir/nir_opt_undef.c
@@ -77,10 +77,7 @@ opt_undef_csel(nir_alu_instr *instr)
static bool
opt_undef_vecN(nir_builder *b, nir_alu_instr *alu)
{
- if (alu->op != nir_op_vec2 &&
- alu->op != nir_op_vec3 &&
- alu->op != nir_op_vec4 &&
- alu->op != nir_op_mov)
+ if (!nir_op_is_vec(alu->op))
return false;
assert(alu->dest.dest.is_ssa);