diff --git a/notes_giant_fft.md b/notes_giant_fft.md index d6494d1..bcd1bdb 100644 --- a/notes_giant_fft.md +++ b/notes_giant_fft.md @@ -100,5 +100,18 @@ Full bit-exact FFT = plan generator (0x2f980 split-radix index algebra) + runtim (3-level tables) + 6 final kernels (each 0x800-0x1200 bytes of vectorized split-radix butterfly) + twiddle. This is the P3 2-4 week body. Architecture fully mapped; transcription not yet done. +### Final kernel 0x1802a24c0 — own vectorized sin/cos, NOT twiddle table +The big-N kernels compute trig ON THE FLY via an AVX polynomial (vfmadd231ps/213ps chain) with +range reduction done by float-bit tricks (vpaddd/vpsubd/vpsrad $0x17 = 23-bit shift = exponent +extract, vpcmpgtd, vblendvps). Polynomial constants (rodata, float, broadcast x8): + 0x181f81fa0 = 0.333366 0x181f81fc0 = -0.250047 0x181f81fe0 = 0.198225 + 0x181f82000 = -0.164625 0x181f82020 = 0.169649 0x181f82040 = -0.151772 + 0x181f82100 = 0.666667 0x181f821c0 = 0.693147 (= ln 2) 0x181f822c0 = 0.75 + (0.693147 = ln 2 ⇒ exp-based sin/cos, SVML-like vector math library.) +=> Small-N path uses the twiddle sin-table (0x39b00); big-N path uses this own polynomial. +Transcribing this bit-exactly = reimplementing a vector math sin/cos (Cody-Waite + poly + exp), +plus the split-radix butterfly + integer reorder — the multi-week P3 body. + +