From 337018fcbb55282182bf175be1e344bffe41c828 Mon Sep 17 00:00:00 2001 From: Karol Herbst Date: Thu, 23 Apr 2026 04:01:27 +0200 Subject: [PATCH] glsl/softfp: rename ffma to fmad They were always implemented as unfused. Reviewed-by: Georg Lehmann Part-of: --- src/compiler/glsl/float32.glsl | 2 +- src/compiler/glsl/float64.glsl | 2 +- src/compiler/nir/nir_lower_double_ops.c | 4 ++-- src/compiler/nir/nir_lower_floats.c | 2 +- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/compiler/glsl/float32.glsl b/src/compiler/glsl/float32.glsl index 70eb998fb1c..7dbafae5d4b 100644 --- a/src/compiler/glsl/float32.glsl +++ b/src/compiler/glsl/float32.glsl @@ -594,7 +594,7 @@ __fmul32(uint a, uint b) } uint -__ffma32(uint a, uint b, uint c) +__fmad32(uint a, uint b, uint c) { return __fadd32(__fmul32(a, b), c); } diff --git a/src/compiler/glsl/float64.glsl b/src/compiler/glsl/float64.glsl index d9dbd86b18d..c65aada6903 100644 --- a/src/compiler/glsl/float64.glsl +++ b/src/compiler/glsl/float64.glsl @@ -955,7 +955,7 @@ __fmul64(uint64_t a, uint64_t b) } uint64_t -__ffma64(uint64_t a, uint64_t b, uint64_t c) +__fmad64(uint64_t a, uint64_t b, uint64_t c) { return __fadd64(__fmul64(a, b), c); } diff --git a/src/compiler/nir/nir_lower_double_ops.c b/src/compiler/nir/nir_lower_double_ops.c index 910af454167..48952d040c8 100644 --- a/src/compiler/nir/nir_lower_double_ops.c +++ b/src/compiler/nir/nir_lower_double_ops.c @@ -655,8 +655,8 @@ lower_doubles_instr_to_soft(nir_builder *b, nir_alu_instr *instr, mangled_name = "__fmul64(u641;u641;"; break; case nir_op_ffma: - name = "__ffma64"; - mangled_name = "__ffma64(u641;u641;u641;"; + name = "__fmad64"; + mangled_name = "__fmad64(u641;u641;u641;"; break; case nir_op_fsat: name = "__fsat64"; diff --git a/src/compiler/nir/nir_lower_floats.c b/src/compiler/nir/nir_lower_floats.c index 99cc40d578f..2bf36f51c97 100644 --- a/src/compiler/nir/nir_lower_floats.c +++ b/src/compiler/nir/nir_lower_floats.c @@ -75,7 +75,7 @@ lower_float_instr_to_soft(nir_builder *b, nir_instr *instr, mangled_name = "__fmul32(u1;u1;"; break; case nir_op_ffma: - mangled_name = "__ffma32(u1;u1;u1;"; + mangled_name = "__fmad32(u1;u1;u1;"; break; case nir_op_fsat: mangled_name = "__fsat32(u1;";