Mesa (master): radeonsi: add 16-bit ALU vectorization

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Tue Sep 22 02:55:26 UTC 2020


Module: Mesa
Branch: master
Commit: 44f1b1be7a3c8859a1fe41d1e899195a651a1f4e
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=44f1b1be7a3c8859a1fe41d1e899195a651a1f4e

Author: Marek Olšák <marek.olsak at amd.com>
Date:   Fri Jul 24 16:15:51 2020 -0400

radeonsi: add 16-bit ALU vectorization

Acked-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer at amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6622>

---

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

diff --git a/src/gallium/drivers/radeonsi/si_shader_nir.c b/src/gallium/drivers/radeonsi/si_shader_nir.c
index 171c2b37203..66fca2bfa53 100644
--- a/src/gallium/drivers/radeonsi/si_shader_nir.c
+++ b/src/gallium/drivers/radeonsi/si_shader_nir.c
@@ -560,6 +560,9 @@ static void si_nir_opts(struct si_screen *sscreen, struct nir_shader *nir, bool
       if (nir->options->max_unroll_iterations) {
          NIR_PASS(progress, nir, nir_opt_loop_unroll, 0);
       }
+
+      if (sscreen->info.has_packed_math_16bit)
+         NIR_PASS(progress, nir, nir_opt_vectorize, NULL, NULL);
    } while (progress);
 }
 



More information about the mesa-commit mailing list