Mesa (main): zink: run more int64 passes during optimization loop if int64 isn't available

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Fri Jun 10 02:49:40 UTC 2022


Module: Mesa
Branch: main
Commit: b59d67431dcd3df2ed8c43daecae1e5ca53dbe7a
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=b59d67431dcd3df2ed8c43daecae1e5ca53dbe7a

Author: Mike Blumenkrantz <michael.blumenkrantz at gmail.com>
Date:   Thu May 19 15:38:26 2022 -0400

zink: run more int64 passes during optimization loop if int64 isn't available

Reviewed-by: Adam Jackson <ajax at redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16669>

---

 src/gallium/drivers/zink/zink_compiler.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/src/gallium/drivers/zink/zink_compiler.c b/src/gallium/drivers/zink/zink_compiler.c
index dc02348a171..9ebbf12768c 100644
--- a/src/gallium/drivers/zink/zink_compiler.c
+++ b/src/gallium/drivers/zink/zink_compiler.c
@@ -470,11 +470,14 @@ optimize_nir(struct nir_shader *s)
    bool progress;
    do {
       progress = false;
+      if (s->options->lower_int64_options)
+         NIR_PASS_V(s, nir_lower_int64);
       NIR_PASS_V(s, nir_lower_vars_to_ssa);
       NIR_PASS(progress, s, nir_lower_alu_to_scalar, filter_pack_instr, NULL);
       NIR_PASS(progress, s, nir_copy_prop);
       NIR_PASS(progress, s, nir_opt_remove_phis);
       if (s->options->lower_int64_options) {
+         NIR_PASS(progress, s, nir_lower_64bit_phis);
          NIR_PASS(progress, s, nir_lower_alu_to_scalar, filter_64_bit_instr, NULL);
       }
       NIR_PASS(progress, s, nir_opt_dce);



More information about the mesa-commit mailing list