i965/nir: use redundant phi optimization
authorConnor Abbott <cwabbott0@gmail.com>
Tue, 3 Feb 2015 06:50:49 +0000 (01:50 -0500)
committerConnor Abbott <cwabbott0@gmail.com>
Tue, 3 Feb 2015 21:00:13 +0000 (16:00 -0500)
Reviewed-by: Jason Ekstrand <jason.ekstrand@intel.com>
Tested-by: Jason Ekstrand <jason.ekstrand@intel.com>
Signed-off-by: Connor Abbott <cwabbott0@gmail.com>
src/mesa/drivers/dri/i965/brw_fs_nir.cpp

index 90980c78800ae9021f9fc0d8d5f6b15ef17200a4..c3c268ca1b326f682207bfe49ffdf83e772b23a5 100644 (file)
@@ -52,6 +52,8 @@ nir_optimize(nir_shader *nir)
       nir_validate_shader(nir);
       progress |= nir_opt_constant_folding(nir);
       nir_validate_shader(nir);
+      progress |= nir_opt_remove_phis(nir);
+      nir_validate_shader(nir);
    } while (progress);
 }