I'm a bit confused about how to choose between the various options dealing with SIMD/FFT. I honestly have little experience with stuff involving the things libsoxr deals with, so my apologies in advance for my misunderstandings.
I read through the other topic here dealing with a simlar issue FFT for double precision on ARM with NEON, and while it does help, I'm not entirely sure I understand everything there.
From what I understand from the CMakeLists.txt in the root directory, libav or PFFFT can be used for SIMD, and will only be used if WITH_SIMD is enabled. In the thread linked above, you state that PFFFT would yield the fastest HQ conversion, but lines 25-34 in the CMakeLists.txt in the src/ directory makes it appear that the functions provided by libav would be preferred if the user enables both libav and PFFFT for some reason. It also seems like you provide a fallback SIMD implementation in case both libav and PFFFT are disabled. Is this understanding right? Are there any guidelines for choosing between the two libraries, or when both libraries should be disabled?
If it helps, I'm building on x86_64.
Thank you for your help,
Alex
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
PFFFT is the best library from a performance perspective; it does however come with a BSD licence, whereas libav FFT has a LGPL licence (the same as the rest of libsoxr). So if having a pure LGPL solution is important, then you should choose AVFFT.
IIRC, there was some issue with PFFFT and ARM (i.e. a soxr build bug that stopped it working properly) that meant AVFFT was the only SIMD option for ARM (but this issue should be fixed now).
I don't think that there is much good reason for disabling both libraries, but if you do then there is still the option to use SIMD in some of the ancillary code, but the speed-ups that this would give are very small compared to using a SIMD FFT as well.
BTW, the latest version in the repository has more SIMD code (in areas other than FFT) than the current released version, so should be the fastest available.
HTH, Rob
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hello robs,
I'm a bit confused about how to choose between the various options dealing with SIMD/FFT. I honestly have little experience with stuff involving the things libsoxr deals with, so my apologies in advance for my misunderstandings.
I read through the other topic here dealing with a simlar issue FFT for double precision on ARM with NEON, and while it does help, I'm not entirely sure I understand everything there.
From what I understand from the CMakeLists.txt in the root directory, libav or PFFFT can be used for SIMD, and will only be used if WITH_SIMD is enabled. In the thread linked above, you state that PFFFT would yield the fastest HQ conversion, but lines 25-34 in the CMakeLists.txt in the src/ directory makes it appear that the functions provided by libav would be preferred if the user enables both libav and PFFFT for some reason. It also seems like you provide a fallback SIMD implementation in case both libav and PFFFT are disabled. Is this understanding right? Are there any guidelines for choosing between the two libraries, or when both libraries should be disabled?
If it helps, I'm building on x86_64.
Thank you for your help,
Alex
Hello Alex, apologies for the confusion!
PFFFT is the best library from a performance perspective; it does however come with a BSD licence, whereas libav FFT has a LGPL licence (the same as the rest of libsoxr). So if having a pure LGPL solution is important, then you should choose AVFFT.
IIRC, there was some issue with PFFFT and ARM (i.e. a soxr build bug that stopped it working properly) that meant AVFFT was the only SIMD option for ARM (but this issue should be fixed now).
I don't think that there is much good reason for disabling both libraries, but if you do then there is still the option to use SIMD in some of the ancillary code, but the speed-ups that this would give are very small compared to using a SIMD FFT as well.
BTW, the latest version in the repository has more SIMD code (in areas other than FFT) than the current released version, so should be the fastest available.
HTH, Rob
Alright, that definitely clears things up. Thanks for the help!
-Alex