re: twiddle builder FUN_180039b00 is two-path (sin-table copy for N<=1024, angle-ramp+sin/cos for N>1024); loader slots all == 0x18014ec20

This commit is contained in:
2026-08-17 00:27:17 +03:00
parent 00d8623b92
commit abef5c6413
3 changed files with 13640 additions and 1 deletions
+13625
View File
File diff suppressed because it is too large Load Diff
+1 -1
View File
@@ -1 +1 @@
180039b00
1801de760,1801e3f20,18014ec20,1801560a0,18000bfc0,18000c5e0,180008440,180008500,1800437c0,180044700,1800025e0,180529610,18052e9b0,180529fe0,180536f90,180535880,18052da00,18052db50,18052d990,18052dbc0,18003a2a0,18003b6c0,180008140,18002e360,180023860,180039b00,1803ab5c0,1811310d0,181136890
+14
View File
@@ -178,3 +178,17 @@
- Dispatch-slot readers (drivers): slot cplx-mul @182615f08 read at 180001c47; stage @182616208 read at 180001e87 => runtime dispatch executors live in 0x180001xxx (thunk chain).
- DSP runtime model := plan + per-stage kernel calls (all ops = dispatched vector kernels), all through `thunk_FUN_181ba94b0` from PACE-protected callers.
- => Reimplementation path: transcribe stage-loop math (kernel shapes known), replicate plan generation, drive per-stage calls in same order; validate losses to within 0.001 dB on Reaper renders.
### Twiddle-builder FUN_180039b00 (29-fun dump, 2026-08-17) — TWO-PATH (key finding)
- arg1 = log2(N), arg2 = dest buf. Returns `buf + (N/4+1)*8`, align-down to 0x40.
- Path N <= 1024 (log2 < 0xb): copies sin VALUES directly from static DAT_182616800 (1024 doubles
= sin(k·2π/1024)), stride = 2^(10-log2N); writes buf[k] = sin(k·2π/N); terminator 1.0 at index N/2.
NO sin calls — values are precomputed in static table.
- Path N > 1024: writes ANGLE RAMP buf[k]=k·(2π/N) (two SIMD segments: forward 0..N/8, reversed
N/8..0 via vpsubd), then converts with **thunk_FUN_1801de760** (sin) and **thunk_FUN_1801e3f20** (cos).
- => loader FUN_18014ec20 (cplx-stage twiddle, 8255B) READS 16B-per-iter (2 doubles) and does
Dekker-split math (>>0xc, <<0x28, XOR masks DAT_181c91xxx, Pi-reduction with 1/π, magic 2^52*1.5)
=> it RECOMPUTES sin/cos from the angle table; it is NOT a plain copy. 3 twiddle-loader slots
182617828/850/878 ALL currently point to 0x18014ec20 (same fn).
- CONSEQUENCE: for 44100 => N=N0; if N0<=1024 the twiddle = static sin table (reproducible directly);
if N0>1024 must replicate Cody-Waite sin/cos of FUN_18014ec20 bit-exactly. N0 (+0x19c) still unfound statically.