Move test helpers into a shared module
Make use of iterative fft preferentially
Add O comment