nak: Change divergence analysis pass order

Always convert to lcssa before divergence analysis

Reviewed-by: Faith Ekstrand <faith.ekstrand@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/34912>
This commit is contained in:
Mel Henning 2025-05-09 20:47:49 -04:00 committed by Marge Bot
parent 666bad5d22
commit a3839dbb90

View file

@ -995,12 +995,13 @@ nak_postprocess_nir(nir_shader *nir,
OPT(nir, nir_opt_combine_barriers, NULL, NULL); OPT(nir, nir_opt_combine_barriers, NULL, NULL);
OPT(nir, nir_convert_to_lcssa, true, true);
nir_divergence_analysis(nir);
if (nir->info.stage == MESA_SHADER_FRAGMENT)
OPT(nir, nir_opt_tex_skip_helpers, true);
nak_optimize_nir(nir, nak); nak_optimize_nir(nir, nak);
if (nir->info.stage == MESA_SHADER_FRAGMENT) {
nir_divergence_analysis(nir);
OPT(nir, nir_opt_tex_skip_helpers, true);
}
OPT(nir, nak_nir_lower_tex, nak); OPT(nir, nak_nir_lower_tex, nak);
OPT(nir, nir_lower_idiv, NULL); OPT(nir, nir_lower_idiv, NULL);