Mesa (master): radeonsi: lower ffma in nir to mad.

Dave Airlie airlied at kemper.freedesktop.org
Tue Oct 10 21:33:45 UTC 2017


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

Author: Dave Airlie <airlied at redhat.com>
Date:   Tue Oct 10 13:23:40 2017 +1000

radeonsi: lower ffma in nir to mad.

This lowers ffma to a * b + c.

This seems like it should keep Marek happiest, so
we'd never get to the fma instruction emission code.

Reviewed-by: Nicolai Hähnle <nicolai.haehnle at amd.com>
Reviewed-by: Marek Olšák <marek.olsak at amd.com>
Signed-off-by: Dave Airlie <airlied at redhat.com>

---

 src/gallium/drivers/radeonsi/si_pipe.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/src/gallium/drivers/radeonsi/si_pipe.c b/src/gallium/drivers/radeonsi/si_pipe.c
index 82ed3d7b52..5b5f83aae1 100644
--- a/src/gallium/drivers/radeonsi/si_pipe.c
+++ b/src/gallium/drivers/radeonsi/si_pipe.c
@@ -795,6 +795,7 @@ static const struct nir_shader_compiler_options nir_options = {
 	.lower_fsat = true,
 	.lower_fdiv = true,
 	.lower_sub = true,
+	.lower_ffma = true,
 	.lower_pack_snorm_2x16 = true,
 	.lower_pack_snorm_4x8 = true,
 	.lower_pack_unorm_2x16 = true,




More information about the mesa-commit mailing list