3131
3232from easybuild .easyblocks .generic .cmakemake import CMakeMake
3333from easybuild .framework .easyconfig import CUSTOM
34- from easybuild .tools import toolchain
34+ from easybuild .tools import toolchain , LooseVersion
3535from easybuild .tools .build_log import EasyBuildError
3636from easybuild .tools .config import build_option
3737from easybuild .tools .environment import setvar
@@ -98,6 +98,8 @@ def configure_step(self):
9898 }
9999
100100 supported_blas_libs = ['AOCL-BLAS' , 'BLIS' , 'NETLIB' , 'OpenBLAS' , 'imkl' ]
101+ if LooseVersion (self .version ) >= LooseVersion ('3.4.5' ):
102+ supported_blas_libs += ['NVPL' ]
101103
102104 # make sure that default backend is a supported library
103105 flexiblas_default = configopts ['FLEXIBLAS_DEFAULT' ]
@@ -123,7 +125,7 @@ def configure_step(self):
123125 if blas_lib == 'imkl' :
124126 # For MKL there is gf_lp64 vs. intel_lp64 and gnu_thread vs. intel_thread (vs. sequential)
125127 # For gf_lp64 vs intel_lp64 the difference is in the ABI for [sz]dot[uc], which FlexiBLAS
126- # can transparenly wrap.
128+ # can transparently wrap.
127129 # gnu_thread vs intel_thread links to libgomp vs. libiomp5 for the OpenMP library.
128130 mkl_gnu_libs = "mkl_gf_lp64;mkl_gnu_thread;mkl_core;gomp;pthread;m;dl"
129131 mkl_intel_libs = "mkl_intel_lp64;mkl_intel_thread;mkl_core;iomp5;pthread;m;dl"
@@ -138,6 +140,11 @@ def configure_step(self):
138140 configopts [key ] = mkl_compiler_mapping [comp_family ]
139141 except KeyError :
140142 raise EasyBuildError ("Compiler family not supported yet: %s" , comp_family )
143+ elif blas_lib == "NVPL" :
144+ # NVPL libraries do not explicitly link any OpenMP runtime,
145+ # but try to lazily and dynamically find the OpenMP runtime in the
146+ # built program. Supported are libgomp, libomp and libnvomp.
147+ configopts [key ] = "nvpl_blas_lp64_gomp;nvpl_blas_core"
141148 elif blas_lib == 'AOCL_mt' :
142149 configopts [key ] = 'blis-mt'
143150 else :
0 commit comments