Mesa (main): pan/lower_framebuffer: Use fmul_imm

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Mon Aug 23 21:08:49 UTC 2021


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

Author: Alyssa Rosenzweig <alyssa at collabora.com>
Date:   Tue Jun 15 12:26:49 2021 -0400

pan/lower_framebuffer: Use fmul_imm

Signed-off-by: Alyssa Rosenzweig <alyssa at collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11383>

---

 src/panfrost/util/pan_lower_framebuffer.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/panfrost/util/pan_lower_framebuffer.c b/src/panfrost/util/pan_lower_framebuffer.c
index 702f872e7f1..b3758eab8ab 100644
--- a/src/panfrost/util/pan_lower_framebuffer.c
+++ b/src/panfrost/util/pan_lower_framebuffer.c
@@ -226,8 +226,8 @@ static nir_ssa_def *
 pan_pack_unorm_8(nir_builder *b, nir_ssa_def *v)
 {
         return pan_replicate_4(b, nir_pack_32_4x8(b,
-                nir_f2u8(b, nir_fround_even(b, nir_fmul(b, nir_fsat(b,
-                        nir_pad_vec4(b, v)), nir_imm_float16(b, 255.0))))));
+                nir_f2u8(b, nir_fround_even(b, nir_fmul_imm(b, nir_fsat(b,
+                        nir_pad_vec4(b, v)), 255.0)))));
 }
 
 /* UNORM 4 is also unpacked to f16, which prevents us from using the shared



More information about the mesa-commit mailing list