From 7ddea94819ccf362b8bce036334b65951f8b2829 Mon Sep 17 00:00:00 2001 From: Rhys Perry Date: Tue, 1 Dec 2020 14:26:40 +0000 Subject: [PATCH] nir/opt_access: don't ignore image arrays in process_variable() Signed-off-by: Rhys Perry Reviewed-by: Connor Abbott Part-of: --- src/compiler/nir/nir_opt_access.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/compiler/nir/nir_opt_access.c b/src/compiler/nir/nir_opt_access.c index d428e29f6ea..b12b263e823 100644 --- a/src/compiler/nir/nir_opt_access.c +++ b/src/compiler/nir/nir_opt_access.c @@ -154,9 +154,9 @@ gather_intrinsic(struct access_state *state, nir_intrinsic_instr *instr) static bool process_variable(struct access_state *state, nir_variable *var) { + const struct glsl_type *type = glsl_without_array(var->type); if (var->data.mode != nir_var_mem_ssbo && - !(var->data.mode == nir_var_uniform && - glsl_type_is_image(var->type))) + !(var->data.mode == nir_var_uniform && glsl_type_is_image(type))) return false; /* Ignore variables we've already marked */