diff --git a/.pick_status.json b/.pick_status.json index cd9aa3ef15d..f42c3283756 100644 --- a/.pick_status.json +++ b/.pick_status.json @@ -1120,7 +1120,7 @@ "description": "glsl: call nir_opt_find_array_copies() when linking", "nominated": true, "nomination_type": 1, - "resolution": 0, + "resolution": 1, "main_sha": null, "because_sha": "d75a36a9eeb1606fab19362746f9b5d94b98bd3a" }, diff --git a/src/compiler/glsl/gl_nir_linker.c b/src/compiler/glsl/gl_nir_linker.c index 0066a878210..40cb08b2bdc 100644 --- a/src/compiler/glsl/gl_nir_linker.c +++ b/src/compiler/glsl/gl_nir_linker.c @@ -56,6 +56,7 @@ gl_nir_opts(nir_shader *nir) nir_var_mem_shared, NULL); + NIR_PASS(progress, nir, nir_opt_find_array_copies); NIR_PASS(progress, nir, nir_opt_copy_prop_vars); NIR_PASS(progress, nir, nir_opt_dead_write_vars); @@ -117,6 +118,8 @@ gl_nir_opts(nir_shader *nir) NIR_PASS(progress, nir, nir_opt_loop_unroll); } } while (progress); + + NIR_PASS_V(nir, nir_lower_var_copies); } static void