diff --git a/src/intel/compiler/brw/brw_nir.c b/src/intel/compiler/brw/brw_nir.c index b8bedec2f1f..4cf7a1359a2 100644 --- a/src/intel/compiler/brw/brw_nir.c +++ b/src/intel/compiler/brw/brw_nir.c @@ -1395,7 +1395,6 @@ brw_nir_optimize(nir_shader *nir, if (nir->info.stage != MESA_SHADER_KERNEL) LOOP_OPT(nir_split_array_vars, nir_var_function_temp); LOOP_OPT(nir_shrink_vec_array_vars, nir_var_function_temp); - LOOP_OPT(nir_opt_deref); LOOP_OPT(nir_lower_vars_to_ssa); if (!nir->info.var_copies_lowered) { /* Only run this pass if nir_lower_var_copies was not called @@ -1687,6 +1686,8 @@ brw_preprocess_nir(const struct brw_compiler *compiler, nir_shader *nir, brw_nir_optimize(nir, devinfo); + OPT(nir_opt_deref); + unsigned lower_flrp = (nir->options->lower_flrp16 ? 16 : 0) | (nir->options->lower_flrp32 ? 32 : 0) |