Skip to content

Commit

Permalink
Merge branch 'jgfouca/cmake_blas_lapack' into next (PR #5972)
Browse files Browse the repository at this point in the history
Merge 2 for this PR.

* jgfouca/cmake_blas_lapack:
  blas/lapack settings should not depend on mpilib
  Refactor blas and lapack stuff a bit more
  • Loading branch information
jgfouca committed Oct 11, 2023
2 parents 6b7cf2d + 26170af commit 7b5906d
Show file tree
Hide file tree
Showing 39 changed files with 6 additions and 39 deletions.
1 change: 0 additions & 1 deletion cime_config/machines/cmake_macros/gnu_anvil.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,4 @@ if (COMP_NAME STREQUAL gptl)
string(APPEND CPPDEFS " -DHAVE_NANOTIME -DBIT64 -DHAVE_SLASHPROC -DHAVE_GETTIMEOFDAY")
endif()
set(PIO_FILESYSTEM_HINTS "gpfs")
set(BLA_VENDOR Intel10_64_dyn)
string(APPEND CXX_LIBS " -lstdc++")
1 change: 0 additions & 1 deletion cime_config/machines/cmake_macros/gnu_badger.cmake
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
set(PIO_FILESYSTEM_HINTS "lustre")
set(MPICXX "mpic++")
set(BLA_VENDOR Intel10_64_dyn)
string(APPEND CXX_LIBS " -lstdc++")
1 change: 0 additions & 1 deletion cime_config/machines/cmake_macros/gnu_bebop.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,3 @@ if (COMP_NAME STREQUAL gptl)
string(APPEND CPPDEFS " -DHAVE_SLASHPROC")
endif()
string(APPEND CXX_LIBS " -lstdc++")
set(BLA_VENDOR Intel10_64_dyn)
1 change: 0 additions & 1 deletion cime_config/machines/cmake_macros/gnu_chrysalis.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,4 @@ if (COMP_NAME STREQUAL gptl)
string(APPEND CPPDEFS " -DHAVE_NANOTIME -DBIT64 -DHAVE_SLASHPROC -DHAVE_GETTIMEOFDAY")
endif()
set(PIO_FILESYSTEM_HINTS "gpfs")
set(BLA_VENDOR Intel10_64_dyn)
string(APPEND CXX_LIBS " -lstdc++")
1 change: 0 additions & 1 deletion cime_config/machines/cmake_macros/gnu_grizzly.cmake
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
set(PIO_FILESYSTEM_HINTS "lustre")
set(MPICXX "mpic++")
set(BLA_VENDOR Intel10_64_dyn)
string(APPEND CXX_LIBS " -lstdc++")
1 change: 0 additions & 1 deletion cime_config/machines/cmake_macros/intel18_snl-blake.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ endif()
if (DEBUG)
string(APPEND FFLAGS " -O0 -g -check uninit -check bounds -check pointers -fpe0 -check noarg_temp_created")
endif()
set(BLA_VENDOR Intel10_64_dyn)
string(APPEND LDFLAGS " -lstdc++")
if (compile_threaded)
string(APPEND LDFLAGS " -qopenmp")
Expand Down
1 change: 0 additions & 1 deletion cime_config/machines/cmake_macros/intel_alvarez.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ string(APPEND CONFIG_ARGS " --host=cray")
if (COMP_NAME STREQUAL gptl)
string(APPEND CPPDEFS " -DHAVE_NANOTIME -DBIT64 -DHAVE_SLASHPROC -DHAVE_GETTIMEOFDAY")
endif()
set(BLA_VENDOR Intel10_64_dyn)
set(CXX_LINKER "FORTRAN")

set(MPICC "cc")
Expand Down
1 change: 0 additions & 1 deletion cime_config/machines/cmake_macros/intel_anvil.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -26,4 +26,3 @@ if (MPILIB STREQUAL impi)
set(MPIFC "mpiifort")
endif()
set(PIO_FILESYSTEM_HINTS "gpfs")
set(BLA_VENDOR Intel10_64_dyn)
1 change: 0 additions & 1 deletion cime_config/machines/cmake_macros/intel_badger.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,4 @@ if (NOT MPILIB STREQUAL impi)
set(MPICXX "mpic++")
endif()
string(APPEND SLIBS " -lpthread")
set(BLA_VENDOR Intel10_64_dyn)
string(APPEND CXX_LIBS " -lstdc++")
1 change: 0 additions & 1 deletion cime_config/machines/cmake_macros/intel_bebop.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,3 @@ if (MPILIB STREQUAL impi)
set(MPICXX "mpiicpc")
set(MPIFC "mpiifort")
endif()
set(BLA_VENDOR Intel10_64_dyn)
1 change: 0 additions & 1 deletion cime_config/machines/cmake_macros/intel_cascade.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,3 @@ if (DEBUG)
string(APPEND FFLAGS " -check all -ftrapuv")
endif()
set(PIO_FILESYSTEM_HINTS "lustre")
set(BLA_VENDOR Intel10_64_dyn)
1 change: 0 additions & 1 deletion cime_config/machines/cmake_macros/intel_chicoma.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -9,4 +9,3 @@ if (NOT MPILIB STREQUAL impi)
endif()
string(APPEND SLIBS " -lpthread")
string(APPEND CXX_LIBS " -lstdc++")
set(BLA_VENDOR Intel10_64_dyn)
1 change: 0 additions & 1 deletion cime_config/machines/cmake_macros/intel_chrysalis.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ if (NOT DEBUG)
string(APPEND FFLAGS " -O3 -qno-opt-dynamic-align")
endif()
set(PIO_FILESYSTEM_HINTS "gpfs")
set(BLA_VENDOR Intel10_64_dyn)
string(APPEND LDFLAGS " -static-intel")
if (MPILIB STREQUAL impi)
set(MPICC "mpiicc")
Expand Down
1 change: 0 additions & 1 deletion cime_config/machines/cmake_macros/intel_compy.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ if (DEBUG)
string(APPEND FFLAGS " -check all -ftrapuv -init=snan")
endif()
set(PIO_FILESYSTEM_HINTS "lustre")
set(BLA_VENDOR Intel10_64_dyn)
string(APPEND SLIBS " -lpmi ")
if (MPILIB STREQUAL impi)
set(MPICC "mpiicc")
Expand Down
1 change: 0 additions & 1 deletion cime_config/machines/cmake_macros/intel_constance.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,4 @@ if (DEBUG)
string(APPEND FFLAGS " -check all -ftrapuv")
endif()
set(PIO_FILESYSTEM_HINTS "lustre")
set(BLA_VENDOR Intel10_64_dyn)
string(APPEND SLIBS " -lpmi")
1 change: 0 additions & 1 deletion cime_config/machines/cmake_macros/intel_ghost.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,3 @@ if (MPILIB STREQUAL mpi-serial AND NOT compile_threaded)
set(PFUNIT_PATH "/projects/ccsm/pfunit/3.2.9/mpi-serial")
endif()
set(PIO_FILESYSTEM_HINTS "lustre")
set(BLA_VENDOR Intel10_64_dyn)
1 change: 0 additions & 1 deletion cime_config/machines/cmake_macros/intel_grizzly.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,4 @@ if (NOT MPILIB STREQUAL impi)
set(MPICXX "mpic++")
endif()
string(APPEND SLIBS " -lpthread")
set(BLA_VENDOR Intel10_64_dyn)
string(APPEND CXX_LIBS " -lstdc++")
1 change: 0 additions & 1 deletion cime_config/machines/cmake_macros/intel_itasca.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -10,5 +10,4 @@ endif()
set(MPICC "mpiicc")
set(MPICXX "mpiicpc")
set(MPIFC "mpiifort")
set(BLA_VENDOR Intel10_64_dyn)
string(APPEND SLIBS " -L/soft/hdf5/hdf5-1.8.13-intel-2013-sp1-update3-impi-5.0.0.028/lib -openmp -fPIC -lpthread -lm")
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
if (COMP_NAME STREQUAL gptl)
string(APPEND CPPDEFS " -DHAVE_VPRINTF -DHAVE_GETTIMEOFDAY")
endif()
set(BLA_VENDOR Intel10_64_dyn)
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
if (COMP_NAME STREQUAL gptl)
string(APPEND CPPDEFS " -DHAVE_VPRINTF -DHAVE_GETTIMEOFDAY")
endif()
set(BLA_VENDOR Intel10_64_dyn)
1 change: 0 additions & 1 deletion cime_config/machines/cmake_macros/intel_narwhal.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,4 @@ string(APPEND CXXFLAGS " -fp-model consistent")
if (NOT DEBUG)
string(APPEND FFLAGS " -qno-opt-dynamic-align")
endif()
set(BLA_VENDOR Intel10_64_dyn)
string(APPEND SLIBS " -lpthread")
1 change: 0 additions & 1 deletion cime_config/machines/cmake_macros/intel_onyx.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,4 @@ string(APPEND FFLAGS " -fimf-use-svml")
if (NOT DEBUG)
string(APPEND FFLAGS " -qno-opt-dynamic-align")
endif()
set(BLA_VENDOR Intel10_64_dyn)
string(APPEND SLIBS " -lpthread")
1 change: 0 additions & 1 deletion cime_config/machines/cmake_macros/intel_pm-cpu.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ string(APPEND CONFIG_ARGS " --host=cray")
if (COMP_NAME STREQUAL gptl)
string(APPEND CPPDEFS " -DHAVE_NANOTIME -DBIT64 -DHAVE_SLASHPROC -DHAVE_GETTIMEOFDAY")
endif()
set(BLA_VENDOR Intel10_64_dyn)
set(CXX_LINKER "FORTRAN")

set(MPICC "cc")
Expand Down
1 change: 0 additions & 1 deletion cime_config/machines/cmake_macros/intel_sandiatoss3.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -9,4 +9,3 @@ if (MPILIB STREQUAL mpi-serial AND NOT compile_threaded)
set(PFUNIT_PATH "/projects/ccsm/pfunit/3.2.9/mpi-serial")
endif()
set(PIO_FILESYSTEM_HINTS "lustre")
set(BLA_VENDOR Intel10_64_dyn)
1 change: 0 additions & 1 deletion cime_config/machines/cmake_macros/intel_sooty.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,4 @@ if (DEBUG)
string(APPEND FFLAGS " -check all -ftrapuv -init=snan")
endif()
set(PIO_FILESYSTEM_HINTS "lustre")
set(BLA_VENDOR Intel10_64_dyn)
string(APPEND SLIBS " -lpmi")
1 change: 0 additions & 1 deletion cime_config/machines/cmake_macros/intel_stampede2.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -12,5 +12,4 @@ string(APPEND FFLAGS " -xCORE-AVX2")
set(HDF5_PATH "$ENV{TACC_HDF5_DIR}")
set(MPI_LIB_NAME "impi")
set(PETSC_PATH "$ENV{PETSC_DIR}")
set(BLA_VENDOR Intel10_64_dyn)
string(APPEND SLIBS " -lpthread")
1 change: 0 additions & 1 deletion cime_config/machines/cmake_macros/intel_tahoma.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ if (DEBUG)
endif()
string(APPEND SLIBS " -L$ENV{HDF5_PATH}/lib -lhdf5_fortran -lhdf5 -lhdf5_hl -lhdf5hl_fortran")
string(APPEND SLIBS " -L$ENV{CURL_PATH}/lib -lcurl")
set(BLA_VENDOR Intel10_64_dyn)
string(APPEND SLIBS " -lpmi")

set(PIO_FILESYSTEM_HINTS "lustre")
Expand Down
1 change: 0 additions & 1 deletion cime_config/machines/cmake_macros/intel_theta.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,4 @@ string(APPEND FFLAGS " -DHAVE_ERF_INTRINSICS")
set(SCC "icc")
set(SCXX "icpc")
set(SFC "ifort")
set(BLA_VENDOR Intel10_64_dyn)
string(APPEND SLIBS " -lpthread")
1 change: 0 additions & 1 deletion cime_config/machines/cmake_macros/intel_warhawk.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,4 @@ string(APPEND CXXFLAGS " -fp-model consistent")
if (NOT DEBUG)
string(APPEND FFLAGS " -qno-opt-dynamic-align")
endif()
set(BLA_VENDOR Intel10_64_dyn)
string(APPEND SLIBS " -lpthread")
1 change: 0 additions & 1 deletion cime_config/machines/cmake_macros/nag_cascade.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -9,4 +9,3 @@ if (MPILIB STREQUAL mvapich2)
set(MPI_PATH "$ENV{MPI_LIB}")
endif()
set(PIO_FILESYSTEM_HINTS "lustre")
set(BLA_VENDOR Intel10_64_dyn)
1 change: 0 additions & 1 deletion cime_config/machines/cmake_macros/nag_constance.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -9,5 +9,4 @@ if (DEBUG)
string(APPEND FFLAGS " -O0 -v")
endif()
set(PIO_FILESYSTEM_HINTS "lustre")
set(BLA_VENDOR Intel10_64_dyn)
string(APPEND SLIBS " -lpmi")
2 changes: 1 addition & 1 deletion cime_config/machines/cmake_macros/oneapi-ifort.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -46,4 +46,4 @@ set(SFC "ifort")
if (compile_threaded)
string(APPEND LDFLAGS " -qopenmp")
endif()
set(BLA_VENDOR Intel10_64_dyn)

Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
set(MPIFC "mpif90")
set(MPICC "mpicc")
set(MPICXX "mpicxx")
set(BLA_VENDOR Intel10_64_dyn)
string(APPEND SLIBS " -fiopenmp -fopenmp-targets=spir64")
1 change: 0 additions & 1 deletion cime_config/machines/cmake_macros/oneapi-ifx_jlse.cmake
Original file line number Diff line number Diff line change
@@ -1,2 +1 @@
set(BLA_VENDOR Intel10_64_dyn)
string(APPEND SLIBS " -fiopenmp -fopenmp-targets=spir64")
2 changes: 0 additions & 2 deletions cime_config/machines/cmake_macros/oneapi-ifx_sunspot.cmake
Original file line number Diff line number Diff line change
@@ -1,3 +1 @@

set(BLA_VENDOR Intel10_64_dyn)
string(APPEND SLIBS " -fiopenmp -fopenmp-targets=spir64")
1 change: 0 additions & 1 deletion cime_config/machines/cmake_macros/oneapi-ifxgpu_jlse.cmake
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@

set(CXX_LINKER "CXX")
set(BLA_VENDOR Intel10_64_dyn)
string(APPEND SLIBS " -fiopenmp -fopenmp-targets=spir64")
set(USE_SYCL "TRUE")
string(APPEND SYCL_FLAGS " -\-intel -fsycl -fsycl-targets=spir64_gen -Xsycl-target-backend \"-device 12.60.7\"") # for pvc node only
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@

set(CXX_LINKER "CXX")
set(BLA_VENDOR Intel10_64_dyn)
string(APPEND SLIBS " -fiopenmp -fopenmp-targets=spir64")
set(USE_SYCL "TRUE")
string(APPEND SYCL_FLAGS " -\-intel -fsycl -fsycl-targets=spir64_gen -Xsycl-target-backend \"-device 12.60.7\"")
Expand Down
1 change: 0 additions & 1 deletion cime_config/machines/cmake_macros/pgi_compy.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ if (COMP_NAME STREQUAL cice)
endif()
set(PIO_FILESYSTEM_HINTS "lustre")
string(APPEND SLIBS " -lpmi")
set(BLA_VENDOR Intel10_64_dyn)
if (MPILIB STREQUAL impi)
set(MPICC "mpipgcc")
set(MPICXX "mpipgcxx")
Expand Down
5 changes: 5 additions & 0 deletions cime_config/machines/config_machines.xml
Original file line number Diff line number Diff line change
Expand Up @@ -268,6 +268,11 @@
<environment_variables compiler="nvidia" mpilib="mpich">
<env name="ADIOS2_ROOT">$SHELL{if [ -z "$ADIOS2_ROOT" ]; then echo /global/cfs/cdirs/e3sm/3rdparty/adios2/2.8.3.patch/cray-mpich-8.1.15/nvidia-21.11; else echo "$ADIOS2_ROOT"; fi}</env>
</environment_variables>
<environment_variables compiler="nvidia">
<env name="BLAS_ROOT">$SHELL{if [ -z "$BLAS_ROOT" ]; then echo /opt/nvidia/hpc_sdk/Linux_x86_64/22.7/compilers; else echo "$BLAS_ROOT"; fi}</env>
<env name="LAPACK_ROOT">$SHELL{if [ -z "$LAPACK_ROOT" ]; then echo /opt/nvidia/hpc_sdk/Linux_x86_64/22.7/compilers; else echo "$LAPACK_ROOT"; fi}</env>
<env name="BLA_VENDOR">NVHPC</env>
</environment_variables>
<environment_variables compiler="amdclang" mpilib="mpich">
<env name="ADIOS2_ROOT">$SHELL{if [ -z "$ADIOS2_ROOT" ]; then echo /global/cfs/cdirs/e3sm/3rdparty/adios2/2.8.3.patch/cray-mpich-8.1.15/aocc-3.2.0; else echo "$ADIOS2_ROOT"; fi}</env>
</environment_variables>
Expand Down

0 comments on commit 7b5906d

Please sign in to comment.