kfrlib / kfr

Fast, modern C++ DSP framework, FFT, Sample Rate Conversion, FIR/IIR/Biquad Filters (SSE, AVX, AVX-512, ARM NEON)
https://www.kfrlib.com
GNU General Public License v2.0
1.65k stars 253 forks source link

Building DFT in GCC and MSVC #70

Open dancazarin opened 4 years ago

dancazarin commented 4 years ago

For now, KFR DFT can be built only using Clang/Xcode.

Building with GCC 7 has been recently added while GCC 8 & 9 have bug described here: https://github.com/kfrlib/kfr/issues/56 that prevents from building correct code for optimized binaries.

MSVC does not work too, because of ICE, out of heap space etc.

All KFR code that does not use DFT works correctly with all these compilers.

mipac commented 4 years ago

in dev branch, what is the dft status?

is it possible to compile with clang 4.0 and link the lib with gcc 6.3 to the main?

dancazarin commented 4 years ago

It's possible to build KFR DFT with clang 6+ and use it with any compatible compiler (GCC 7+). Older versions may be supported too (and were supported in previous versions of KFR), you can test.

If you need DFT only and can use dynamic linking, you can build KFR C API (clang required). Then the resulting shared library can be used with any C compiler.

All changes required to build C API are already published in dev branch.

mipac commented 4 years ago

I need to test Thank you very much for your answer

reFX-Mike commented 4 years ago

Is this still an issue with the latest msvc 2019 16.6.3? If yes, wouldn’t it make sense to report it to MS?

mipac commented 4 years ago

i've test on debian

it works 👍

reFX-Mike commented 2 years ago

Now that MSVC 2022 is out and available as 64-bit, can somebody try again if the DFT compiles successfully now?

LCVitality commented 1 year ago

Now that MSVC 2022 is out and available as 64-bit, can somebody try again if the DFT compiles successfully now?

I tried with vs2022 17.5, the compilation was passed but the speed of the dft example was 5-10 times slower than clang. I modified the data size of that example to 65536 * 2.