diff --git a/src/compiler/nir/nir_loop_analyze.c b/src/compiler/nir/nir_loop_analyze.c index 65737f8f9f3..099c55bffb5 100644 --- a/src/compiler/nir/nir_loop_analyze.c +++ b/src/compiler/nir/nir_loop_analyze.c @@ -1308,7 +1308,7 @@ force_unroll_array_access(loop_info_state *state, nir_deref_instr *deref, { unsigned array_size = find_array_access_via_induction(state, deref, NULL); if (array_size) { - if ((array_size == state->loop->info->max_trip_count) && + if ((array_size >= state->loop->info->max_trip_count) && nir_deref_mode_must_be(deref, nir_var_shader_in | nir_var_shader_out | nir_var_shader_temp |