Skip to content

v0.28.0 — opt-in FMA mode

Choose a tag to compare

@tannevaled tannevaled released this 25 Oct 17:52
· 3 commits to main since this release
e27cdab

New: an opt-in FMA mode (Options.FMA, with NewPlanWith, NewRealPlanWith, NewPlanNWith, NewRealPlan2With, FFTWith, RFFTWith, FFTNWith). Rounds 41–42.

  • Default unchanged: without the option, every transform returns exactly the bits of v0.27.x (checked on Cascade Lake and Zen 3 over 4,200 transforms).
  • With FMA, on amd64 CPUs with FMA3, plans use fused multiply-add kernels chosen per pass from a measured table per CPU, so an FMA plan is never slower than the default (worst row 0.990×, within placement noise). Elsewhere the option runs the default kernels.
  • Radix 32 with FMA (go-asmgen v0.20.0 builders): on Cascade Lake, complex 1,024 goes from 1.19 to 0.94 × FFTW, RFFT 4,096 from 1.03 to 0.94, complex 256 from 1.05 to 0.96. On Zen 3 radix 32 does not pay; complex 1,024 goes from 1.13 to 1.10 × FFTW.
  • Rows within 5% of FFTW (of 24): Zen 3 19 → 20, Cascade Lake 17 → 18.
  • Accuracy: relative error against long double on the exact inputs, FMA ÷ default, 0.76–1.08 over 90 transforms. Every FMA kernel is bit-identical to a math.FMA Go reference.
  • Every path honours the option: real transforms, Rader/Bluestein, N-D strips (all lengths 2–2000 checked, including 9·p).
  • CI: the qemu jobs run on ubuntu-24.04 (ubuntu-latest 26.04 cannot install qemu-user-static).

Details: BENCHMARKS.md, Rounds 41 and 42. #80 (supersedes #77).