From 4875c82d2d81c71ac94eead9e49524a32b03b378 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Daniel=20Sch=C3=BCrmann?= Date: Tue, 4 Jan 2022 09:59:07 +0000 Subject: [PATCH] radv: call nir_lower_vars_to_ssa later MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Totals from 599 (0.44% of 134913) affected shaders: (GFX10.3) CodeSize: 1243732 -> 1240512 (-0.26%); split: -0.26%, +0.00% Instrs: 223370 -> 222702 (-0.30%); split: -0.30%, +0.00% Latency: 901762 -> 885446 (-1.81%); split: -1.81%, +0.00% InvThroughput: 305546 -> 305536 (-0.00%) SClause: 12690 -> 12554 (-1.07%); split: -1.13%, +0.06% Copies: 23779 -> 23778 (-0.00%) PreSGPRs: 17781 -> 17829 (+0.27%) Acked-by: Timur Kristóf Reviewed-by: Rhys Perry Part-of: --- src/amd/vulkan/radv_shader.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/amd/vulkan/radv_shader.c b/src/amd/vulkan/radv_shader.c index 6d446e3..707d8d7 100644 --- a/src/amd/vulkan/radv_shader.c +++ b/src/amd/vulkan/radv_shader.c @@ -153,8 +153,6 @@ radv_optimize_nir(struct nir_shader *shader, bool optimize_conservatively, bool NIR_PASS(progress, shader, nir_split_array_vars, nir_var_function_temp); NIR_PASS(progress, shader, nir_shrink_vec_array_vars, nir_var_function_temp); - NIR_PASS_V(shader, nir_lower_vars_to_ssa); - if (allow_copies) { /* Only run this pass in the first call to * radv_optimize_nir. Later calls assume that we've @@ -166,6 +164,7 @@ radv_optimize_nir(struct nir_shader *shader, bool optimize_conservatively, bool NIR_PASS(progress, shader, nir_opt_copy_prop_vars); NIR_PASS(progress, shader, nir_opt_dead_write_vars); + NIR_PASS_V(shader, nir_lower_vars_to_ssa); NIR_PASS_V(shader, nir_lower_alu_to_scalar, NULL, NULL); NIR_PASS_V(shader, nir_lower_phis_to_scalar, true); -- 2.7.4