diff --git a/Makefile b/Makefile index f65a80eeaa17e341d18c35f65ecf586c6b5a6746..7c98d0f4f214dc8470a8b0f5f53db552a5a96426 100755 --- a/Makefile +++ b/Makefile @@ -27,9 +27,16 @@ CFLAGS += -I./ FFTWLIBS = + # ======================================================== -# CODE OPTIONS -# +# CODE OPTIONS FOR THE COMPILATION +# (refer to the RICK wiki here +# https://www.ict.inaf.it/gitlab/claudio.gheller/hpc_imaging/-/wikis/home) +# ======================================================== + + +# PARALLEL FFT IMPLEMENTATION + # use FFTW (it can be switched on ONLY if MPI is active) OPT += -DUSE_FFTW @@ -40,37 +47,36 @@ OPT += -DUSE_FFTW # switch on the OpenMP parallelization #OPT += -DUSE_OMP -# write the full 3D cube of gridded visibilities and its FFT transform -#OPT += -DWRITE_DATA +# ======================================================== + +# ACTIVATE PIECES OF THE CODE TO BE PERFORMED -# write the final image -OPT += -DWRITE_IMAGE # perform w-stacking phase correction OPT += -DPHASE_ON -# Support CFITSIO !!! Remember to add the path to the CFITSIO library to LD_LIBRARY_PATH -#OPT += -DFITSIO - # Normalize uvw in case it is not done in the binMS #OPT += -DNORMALIZE_UVW -# Gridding kernel: GAUSS, GAUSS_HI_PRECISION, KAISERBESSEL +# ======================================================== + +# SELECT THE GRIDDING KERNEL: GAUSS, GAUSS_HI_PRECISION, KAISERBESSEL + + OPT += -DGAUSS_HI_PRECISION #OPT += -DGAUSS #OPT += -DKAISERBESSEL -#OPT += -DVERBOSE - # ======================================================== -# ACCELERATION -# + +# GPU OFFLOADING OPTIONS + #OPT += -DNVIDIA -#use cuda for GPUs +# use CUDA for GPUs #OPT += -DCUDACC # use GPU acceleration via OMP @@ -82,26 +88,47 @@ OPT += -DGAUSS_HI_PRECISION # use NVIDIA GPU to perform the reduce #OPT += -DNCCL_REDUCE -# use AMD GPU to perform the reduce -#OPT += -DRCCL_REDUCE - # use GPU to perform FFT #OPT += -DCUFFTMP -#support for AMD GPUs +# FULL GPU SUPPORT - Recommended for full NVIDIA GPU code execution +OPT += -DFULL_NVIDIA +ifeq (FULL_NVIDIA,$(findstring FULL_NVIDIA,$(OPT))) +OPT += -DCUDACC -DNCCL_REDUCE -DCUFFTMP +endif + +# support for AMD GPUs #OPT += __HIP_PLATFORM_AMD__ +# use AMD GPU to perform the reduce +#OPT += -DRCCL_REDUCE + +# ======================================================= + +# OUTPUT HANDLING + + +# Support CFITSIO !!! Remember to add the path to the CFITSIO library to LD_LIBRARY_PATH +#OPT += -DFITSIO + +# write the full 3D cube of gridded visibilities and its FFT transform +#OPT += -DWRITE_DATA + +# write the final image +OPT += -DWRITE_IMAGE + +# ======================================================= + +# DEVELOPING OPTIONS + + +#OPT += -DVERBOSE + #perform the debugging in the ring implementation #OPT += -DDEBUG -# ======================================================== - -# ======================================================== -#FULL GPU SUPPORT!!! -OPT += -DFULL_NVIDIA -ifeq (FULL_NVIDIA,$(findstring FULL_NVIDIA,$(OPT))) -OPT += -DCUDACC -DNCCL_REDUCE -DCUFFTMP -endif +# ======================================================= +# END OF OPTIONS # ======================================================= ifeq (USE_OMP,$(findstring USE_OMP,$(OPT)))