diff --git a/crates/math/src/lib.rs b/crates/math/src/lib.rs index fee95bc10af3..ae305cd9df61 100644 --- a/crates/math/src/lib.rs +++ b/crates/math/src/lib.rs @@ -272,8 +272,10 @@ impl WasmFloat for f64 { } #[inline] fn mul_add(self, b: f64, c: f64) -> f64 { + // The MinGW implementation of `fma` differs from other platforms, so + // favor `libm` there instead. #[cfg(feature = "std")] - if true { + if !(cfg!(windows) && cfg!(target_env = "gnu")) { return self.mul_add(b, c); } libm::fma(self, b, c)