mirror of
https://gitee.com/openharmony/third_party_mesa3d
synced 2024-11-27 09:31:03 +00:00
radv: use nir_opt_copy_prop_vars and nir_opt_dead_write_vars
Totals from affected shaders: SGPRS: 2856 -> 2856 (0.00 %) VGPRS: 3236 -> 3248 (0.37 %) Spilled SGPRs: 0 -> 0 (0.00 %) Spilled VGPRs: 0 -> 0 (0.00 %) Private memory VGPRs: 0 -> 0 (0.00 %) Scratch size: 0 -> 0 (0.00 %) dwords per thread Code Size: 236560 -> 233548 (-1.27 %) bytes LDS: 0 -> 0 (0.00 %) blocks Max Waves: 277 -> 283 (2.17 %) Wait states: 0 -> 0 (0.00 %) Even in the cases were we have increased VGPR use it appears the NIR is improved significantly. Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
This commit is contained in:
parent
67a2c1493c
commit
9d5b106b2e
@ -127,6 +127,10 @@ radv_optimize_nir(struct nir_shader *shader, bool optimize_conservatively)
|
||||
|
||||
NIR_PASS_V(shader, nir_lower_vars_to_ssa);
|
||||
NIR_PASS_V(shader, nir_lower_pack);
|
||||
|
||||
NIR_PASS(progress, shader, nir_opt_copy_prop_vars);
|
||||
NIR_PASS(progress, shader, nir_opt_dead_write_vars);
|
||||
|
||||
NIR_PASS_V(shader, nir_lower_alu_to_scalar);
|
||||
NIR_PASS_V(shader, nir_lower_phis_to_scalar);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user