[ANN] FFTL.jl: a pure-Julia FFT (CPU, GPU, and a C library via juliac)

Hi all,

I’d like to announce FFTL.jl (“Fastest Fourier Transform in Lübeck”). It’s an FFT written entirely in Julia, MIT-licensed, and registered in General.

What it does

  • Complex, real-input and all eleven real-to-real kinds of FFTW (DCT, DST, Hartley, halfcomplex), for any length, along any subset of dimensions
  • Float32/Float64 on a SIMD, multithreaded fast path, plus BigFloat, Double64, Float128 etc. in their own precision
  • GPUs through KernelAbstractions.jl (tuned on CUDA and Metal)
  • AbstractFFTs plans, and the same function names and conventions as FFTW.jl, so using FFTL can usually replace using FFTW

A C library from the same Julia code. libfftl compiles the package with juliac --trim=safe (Julia ≥ 1.12) into a shared library with FFTW3’s C and Fortran interface. Programs written for FFTW3 can link against it without source changes. No transform is written in C. The only dependency is the Julia runtime that ships next to the library, so no Julia installation is needed. I think this is a nice demonstration of what trimming makes possible. Kudos to the JuliaC team!

FFTL was developed by a coding agent under my guidance since I needed a fast, pure Julia FFT at the core of my package NFFT, which also got an agent upgrade.

The benchmarks page (Benchmarks | FFTL.jl) compares FFTL with FFTW, ducc0, vDSP, cuFFT and VkFFT, and describes the protocol. FFTL is competitive in many cases and behind in others (some non-smooth lengths, some GPU cases). The docs say where.

My hope is that FFTL could become the Julia community’s FFT, built together rather than spread over several packages. I am very grateful for the first contributions which already improved the performance in many aspects.

Contributions and feedback welcome! Agentic coding is new to me, and I’d be grateful for advice on how to set up better guardrails, instructions, benchmarks etc. to improve the package.

On a side note: I teach signal processing at the University of Lübeck and yesterday introduced the core idea of the FFT, which is always so much fun because of the beauty of the derivation.

Tobias

I made a similar project just two months ago, with the help of AI as well, haha :laughing:

Nice! Is it public? I’d be curious to compare, and if there are ideas or kernels that FFTL is missing.