From: Ian Romanick <ian.d.roman...@intel.com>

Withouth this, a pattern that creates a sequence that another pattern
can match will never perform the second match.  This can mean either
lost optimization opportunity (and a lot of frustration... "Why the
%@#$ isn't my optimization happening?!?") or, even worse, missed
lowering.

No shader-db changes on any platform.

Signed-off-by: Ian Romanick <ian.d.roman...@intel.com>
---
 src/intel/compiler/brw_nir.c | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/src/intel/compiler/brw_nir.c b/src/intel/compiler/brw_nir.c
index 31ffbe613ec..4a6e9560643 100644
--- a/src/intel/compiler/brw_nir.c
+++ b/src/intel/compiler/brw_nir.c
@@ -776,7 +776,10 @@ brw_postprocess_nir(nir_shader *nir, const struct 
brw_compiler *compiler,
       OPT(brw_nir_opt_peephole_ffma);
    }
 
-   OPT(nir_opt_algebraic_late);
+   do {
+      progress = false;
+      OPT(nir_opt_algebraic_late);
+   } while (progress);
 
    OPT(nir_lower_to_source_mods);
    OPT(nir_copy_prop);
-- 
2.14.4

_______________________________________________
mesa-dev mailing list
mesa-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/mesa-dev

Reply via email to