为什么文档说要使用 vDSP_DFT 而不是 FFT

Why does the documentation say to use the vDSP_DFT instead of FFT

在 Apple 文档中,它说

We suggest you use the DFT routines instead of these.

Use the DFT routines instead of these wherever possible. (For example, instead of calling vDSP_fft_zip with a setup created with vDSP_create_fftsetup, call vDSP_DFT_Execute(::::_:) with a setup created with vDSP_DFT_zop_CreateSetup(::_:).)

apple vDSP docs

使用 DFT 例程有什么优势?

DFT 例程更新,具有更通用的界面,并且具有旧界面所没有的一些功能。

一个特点是 DFT 例程使用通用设置数据库——当您创建 DFT 设置时,您可以传递以前的设置,如果合适它会共享一些数据。

我希望 API 的某些部分有所改进。例如,在创建 DFT 设置时,您只需指定所需的长度。使用 FFT,您必须指定除以长度的最大 2 次幂,并分别指定您想要它的一倍、三倍还是五倍。

在幕后,例程共享代码,因此在大多数情况下应该可以忽略不计的性能差异。