Skip to content

Commit 08060a0

Browse files
authored
Merge pull request #239 from jedwards4b/openmpi_derecho
add openmpi support on derecho
2 parents 940bd80 + 5bb49db commit 08060a0

File tree

4 files changed

+16
-5
lines changed

4 files changed

+16
-5
lines changed

machines/cmake_macros/CNL.cmake

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,9 @@ endif()
66
set(MPICC "cc")
77
set(MPICXX "CC")
88
set(MPIFC "ftn")
9-
set(NETCDF_PATH "$ENV{NETCDF_DIR}")
10-
set(PIO_FILESYSTEM_HINTS "lustre")
11-
set(PNETCDF_PATH "$ENV{PARALLEL_NETCDF_DIR}")
129
set(SCC "cc")
1310
set(SCXX "CC")
1411
set(SFC "ftn")
12+
set(NETCDF_PATH "$ENV{NETCDF_DIR}")
13+
set(PIO_FILESYSTEM_HINTS "lustre")
14+
set(PNETCDF_PATH "$ENV{PARALLEL_NETCDF_DIR}")

machines/cmake_macros/nvhpc.cmake

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ else()
99
string(APPEND CXXFLAGS " -O0 -Mnofma -g -Wall -Kieee -traceback")
1010
string(APPEND FFLAGS " -O0 -g -Ktrap=fp -Mbounds -Kieee")
1111
endif()
12-
string(APPEND CPPDEFS " -DFORTRANUNDERSCORE -DNO_SHR_VMATH -DNO_R16 -DCPRNVIDIA")
12+
string(APPEND CPPDEFS " -DFORTRANUNDERSCORE -DNO_SHR_VMATH -DNO_R16 -DCPRNVIDIA -DNO_QUAD_PRECISION")
1313
set(CXX_LINKER "CXX")
1414
set(FC_AUTO_R8 "-r8")
1515
string(APPEND FFLAGS " -i4 -gopt -time -Mextend -byteswapio -Mflushz -Kieee")

machines/derecho/config_machines.xml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
<DESC>NCAR AMD EPYC system</DESC>
33
<OS>CNL</OS>
44
<COMPILERS>intel,gnu,nvhpc,cray</COMPILERS>
5-
<MPILIBS>mpich</MPILIBS>
5+
<MPILIBS>mpich,openmpi</MPILIBS>
66
<CIME_OUTPUT_ROOT>$ENV{SCRATCH}</CIME_OUTPUT_ROOT>
77
<DIN_LOC_ROOT>$ENV{CESMDATAROOT}/inputdata</DIN_LOC_ROOT>
88
<DIN_LOC_ROOT_CLMFORC>$ENV{CESMDATAROOT}/inputdata/atm/datm7</DIN_LOC_ROOT_CLMFORC>
@@ -76,6 +76,9 @@
7676
<modules>
7777
<command name="load">ncarcompilers/1.0.0</command>
7878
</modules>
79+
<modules mpilib="openmpi" compiler="!gnu">
80+
<command name="load">openmpi/5.0.7</command>
81+
</modules>
7982
<modules mpilib="mpich" compiler="!gnu">
8083
<command name="load">cray-mpich/8.1.29</command>
8184
</modules>

machines/derecho/derecho.cmake

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,3 +12,11 @@ endif()
1212
# If we want to use cray-libsci instead of mkl uncomment this line as well as the module in config_machines.xml
1313
string(REPLACE "-mkl=cluster" "" SLIBS "${SLIBS}")
1414
string(APPEND CPPDEFS " -DHAVE_GETTID")
15+
if (MPILIB STREQUAL openmpi)
16+
set(MPICC "mpicc")
17+
set(MPICXX "mpicxx")
18+
set(MPIFC "mpif90")
19+
set(SCC "$ENV{CC}")
20+
set(SCXX "$ENV{CXX}")
21+
set(SFC "$ENV{FC}")
22+
endif()

0 commit comments

Comments
 (0)