mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-07 02:48:06 +02:00
radv: remove some unneeded passes from radv_nir_lower_io_vars_to_scalar
No Foz-DB changes on Navi48. Reviewed-by: Marek Olšák <marek.olsak@amd.com> Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com> Acked-by: Daniel Schürmann <daniel@schuermann.dev> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40955>
This commit is contained in:
parent
e0883d107a
commit
f001afad23
1 changed files with 0 additions and 20 deletions
|
|
@ -31,26 +31,6 @@ radv_nir_lower_io_vars_to_scalar(nir_shader *nir, nir_variable_mode mask)
|
|||
/* Optimize the new vector code and then remove dead vars */
|
||||
NIR_PASS(_, nir, nir_opt_copy_prop);
|
||||
NIR_PASS(_, nir, nir_opt_shrink_vectors, true);
|
||||
|
||||
if (mask & nir_var_shader_out) {
|
||||
/* Optimize swizzled movs of load_const for nir_link_opt_varyings's constant propagation. */
|
||||
NIR_PASS(_, nir, nir_opt_constant_folding);
|
||||
|
||||
/* For nir_link_opt_varyings's duplicate input opt */
|
||||
NIR_PASS(_, nir, nir_opt_cse);
|
||||
}
|
||||
|
||||
/* Run copy-propagation to help remove dead output variables (some shaders have useless copies
|
||||
* to/from an output), so compaction later will be more effective.
|
||||
*
|
||||
* This will have been done earlier but it might not have worked because the outputs were
|
||||
* vector.
|
||||
*/
|
||||
if (nir->info.stage == MESA_SHADER_TESS_CTRL)
|
||||
NIR_PASS(_, nir, nir_opt_copy_prop_vars);
|
||||
|
||||
NIR_PASS(_, nir, nir_opt_dce);
|
||||
NIR_PASS(_, nir, nir_remove_dead_variables, nir_var_function_temp | nir_var_shader_in | nir_var_shader_out, NULL);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue