[llvm] [WebAssembly] Lower fmuladd to fma (PR #161355)

Jasmine Tang via llvm-commits llvm-commits at lists.llvm.org
Thu Oct 2 13:45:22 PDT 2025


================
@@ -103,9 +136,8 @@ define <4 x float> @fmuladd_4xf32(<4 x float> %a, <4 x float> %b, <4 x float> %c
 ; RELAXED-LABEL: fmuladd_4xf32:
 ; RELAXED:         .functype fmuladd_4xf32 (v128, v128, v128) -> (v128)
 ; RELAXED-NEXT:  # %bb.0:
-; RELAXED-NEXT:    f32x4.mul $push0=, $0, $1
-; RELAXED-NEXT:    f32x4.add $push1=, $pop0, $2
----------------
badumbatish wrote:

oh i see, i'm also not quite sure how to reconcile with the relaxed-simd madd's optional round once or twice. if we're going from fma (i assume is just rounding once) to relaxed madd (optionally rounding once or twice), and the platform that runs relaxed madd can only support rounding twice, isn't that some what dangerous?

https://github.com/llvm/llvm-project/pull/161355


More information about the llvm-commits mailing list