Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

RFFT improvement: remove the double size memory requirement #1367

Open
wants to merge 2 commits into
base: develop
Choose a base branch
from

Conversation

yairchu
Copy link

@yairchu yairchu commented Mar 25, 2024

On 2017, the JUCE team showed interest in fixing the double size memory requirement of juce::FFT, this PR does this while also removing duplication and complication in the code.

Fabian originally suggested making the FFTFallback's real transform more efficient and avoid producing the intermediate redundant results, but given that it is simply the fallback engine, I chose a method that makes it even less efficient (by using additional memory buffers), as I don't see making it efficient as any priority. In fact, I would consider simplifying the fallback engine even further by removing the conditional allocas in it.

yairchu added 2 commits March 25, 2024 15:56
This makes the FFT engine wrappers simpler, deduplicates code (reducing potential for bugs in wrappers),
at the cost of making the FallbackFFT's redundant work done again if the legacy flag is used.
Ideally rfft would be implemented more efficiently than doing a full FFT,
but the FFTFallback is just a slow fill-in for juce::dsp::FFT to still work in the absence of using an external FFT engine.
This makes it function like the other engines in not requiring an oversized buffer.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant