VkFFT icon indicating copy to clipboard operation
VkFFT copied to clipboard

vkFFT backend module

Open davebayer opened this issue 1 year ago • 2 comments

This merge request introduces vkFFT_Backend module that defines VKFFT_BACKEND_* macro for each backend ID and VKFFT_BACKEND_IS_* macro defined as (VKFFT_BACKEND == VKFFT_BACKEND_*). It makes the backend's specific sections more explicit than comparing VKFFT_BACKEND to some value.

Also a check if VKFFT_BACKEND macro is defined is added to the module.

davebayer avatar Mar 08 '24 21:03 davebayer

More changes:

  • CMake version is upgraded to version 3.17
    • we can use CUDAToolkit instead of depricated CUDA package
    • unity build can be used to significantly reduce compile times
    • clear up whole file, divided into sections, some comments were added
  • chosen VKFFT_BACKEND can be passed to CMake via number (as it was) or by string, e. g. -DVKFFT_BACKEND=CUDA
  • CUDA language is completely removed from the project as it was unnecessary
    • all .cu benchmarks and precision files were renamed to .cpp
    • enable_language was removed from CMake as well as CUDA language configurations

davebayer avatar Mar 09 '24 12:03 davebayer

Hello,

The changes to VKFFT_BACKEND look cosmetic to me but if they can make the code more clear to others I am happy to add them. However, instead of adding the new file, all definitions should be made in the vkFFT.h file - it is an entry point to the whole library and library-wide definitions are stored in it. As for the CMakeLists changes, I need to look further into them and I think they are better done as a separate pr.

Best regards, Dmitrii

DTolm avatar Mar 22 '24 14:03 DTolm