Mesa (main): nir_to_tgsi: Lower uadd_sat/usub_sat.
GitLab Mirror
gitlab-mirror at kemper.freedesktop.org
Wed Jul 13 08:09:58 UTC 2022
Module: Mesa
Branch: main
Commit: d472c45810c15d744981f68ca375fcbc47f29b42
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=d472c45810c15d744981f68ca375fcbc47f29b42
Author: Georg Lehmann <dadschoorse at gmail.com>
Date: Tue Jul 12 20:27:12 2022 +0200
nir_to_tgsi: Lower uadd_sat/usub_sat.
Signed-off-by: Georg Lehmann <dadschoorse at gmail.com>
Reviewed-by: Emma Anholt <emma at anholt.net>
Reviewed-by: Jason Ekstrand <jason.ekstrand at collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17468>
---
src/gallium/auxiliary/nir/nir_to_tgsi.c | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/src/gallium/auxiliary/nir/nir_to_tgsi.c b/src/gallium/auxiliary/nir/nir_to_tgsi.c
index 390a532b546..9532b81e197 100644
--- a/src/gallium/auxiliary/nir/nir_to_tgsi.c
+++ b/src/gallium/auxiliary/nir/nir_to_tgsi.c
@@ -3540,6 +3540,7 @@ ntt_fix_nir_options(struct pipe_screen *screen, struct nir_shader *s,
!options->lower_flrp64 ||
!options->lower_fmod ||
!options->lower_rotate ||
+ !options->lower_uadd_sat ||
!options->lower_uniforms_to_ubo ||
!options->lower_vector_cmp ||
options->lower_fsqrt != lower_fsqrt ||
@@ -3556,7 +3557,8 @@ ntt_fix_nir_options(struct pipe_screen *screen, struct nir_shader *s,
new_options->lower_flrp64 = true;
new_options->lower_fmod = true;
new_options->lower_rotate = true;
- new_options->lower_uniforms_to_ubo = true,
+ new_options->lower_uadd_sat = true;
+ new_options->lower_uniforms_to_ubo = true;
new_options->lower_vector_cmp = true;
new_options->lower_fsqrt = lower_fsqrt;
new_options->force_indirect_unrolling = no_indirects_mask;
@@ -3907,6 +3909,7 @@ static const nir_shader_compiler_options nir_to_tgsi_compiler_options = {
.lower_fmod = true,
.lower_rotate = true,
.lower_uniforms_to_ubo = true,
+ .lower_uadd_sat = true,
.lower_vector_cmp = true,
.lower_int64_options = nir_lower_imul_2x32_64,
.use_interpolated_input_intrinsics = true,
More information about the mesa-commit
mailing list