From a9ee9f096a63e86ceb4418bdb4f1492c4e8c9ed9 Mon Sep 17 00:00:00 2001 From: David Burrows Date: Thu, 17 Oct 2024 14:33:02 -0400 Subject: [PATCH 1/3] update module file after Gaea-C5 OS upgrade --- modulefiles/gaea.lua | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/modulefiles/gaea.lua b/modulefiles/gaea.lua index 0330849a7..015deaeb2 100644 --- a/modulefiles/gaea.lua +++ b/modulefiles/gaea.lua @@ -7,10 +7,10 @@ whatis([===[Loads libraries needed for building the UPP on Gaea ]===]) prepend_path("MODULEPATH", "/autofs/ncrc-svm1_proj/epic/spack-stack/spack-stack-1.6.0/envs/upp-addon-env/install/modulefiles/Core") -stack_intel_ver=os.getenv("stack_intel_ver") or "2023.1.0" +stack_intel_ver=os.getenv("stack_intel_ver") or "2023.2.0" load(pathJoin("stack-intel", stack_intel_ver)) -stack_cray_mpich_ver=os.getenv("stack_cray_mpich_ver") or "8.1.25" +stack_cray_mpich_ver=os.getenv("stack_cray_mpich_ver") or "8.1.28" load(pathJoin("stack-cray-mpich", stack_cray_mpich_ver)) cmake_ver=os.getenv("cmake_ver") or "3.23.1" From 620f4effb2e7e5b82ded99ab8f7a2bc059f99de8 Mon Sep 17 00:00:00 2001 From: DavidBurrows-NCO Date: Fri, 18 Oct 2024 11:15:39 -0400 Subject: [PATCH 2/3] update and split modulefiles for gaea c5 and c6 builds --- modulefiles/{gaea.lua => gaeac5.lua} | 6 ++--- modulefiles/gaeac6.lua | 28 +++++++++++++++++++++++ tests/compile_upp.sh | 33 ++++++++++++++++++++++++---- 3 files changed, 60 insertions(+), 7 deletions(-) rename modulefiles/{gaea.lua => gaeac5.lua} (86%) create mode 100644 modulefiles/gaeac6.lua diff --git a/modulefiles/gaea.lua b/modulefiles/gaeac5.lua similarity index 86% rename from modulefiles/gaea.lua rename to modulefiles/gaeac5.lua index 015deaeb2..fd5d80df7 100644 --- a/modulefiles/gaea.lua +++ b/modulefiles/gaeac5.lua @@ -1,9 +1,9 @@ help([[ This module loads libraries required for building and running UPP - on the NOAA RDHPC machine Gaea C5 using Intel-2023.1.0. + on the NOAA RDHPC machine Gaea C5 using Intel-2023.2.0. ]]) -whatis([===[Loads libraries needed for building the UPP on Gaea ]===]) +whatis([===[Loads libraries needed for building the UPP on Gaea C5 ]===]) prepend_path("MODULEPATH", "/autofs/ncrc-svm1_proj/epic/spack-stack/spack-stack-1.6.0/envs/upp-addon-env/install/modulefiles/Core") @@ -25,4 +25,4 @@ setenv("CC","cc") setenv("CXX","CC") setenv("FC","ftn") -setenv("CMAKE_Platform","gaea.intel") +setenv("CMAKE_Platform","gaeac5.intel") diff --git a/modulefiles/gaeac6.lua b/modulefiles/gaeac6.lua new file mode 100644 index 000000000..5ab499aa1 --- /dev/null +++ b/modulefiles/gaeac6.lua @@ -0,0 +1,28 @@ +help([[ + This module loads libraries required for building and running UPP + on the NOAA RDHPC machine Gaea C6 using Intel-2023.2.0. +]]) + +whatis([===[Loads libraries needed for building the UPP on Gaea C6 ]===]) + +prepend_path("MODULEPATH", "/autofs/ncrc-svm1_proj/epic/spack-stack/spack-stack-1.6.0/envs/upp-addon-env/install/modulefiles/Core") + +stack_intel_ver=os.getenv("stack_intel_ver") or "2023.2.0" +load(pathJoin("stack-intel", stack_intel_ver)) + +stack_cray_mpich_ver=os.getenv("stack_cray_mpich_ver") or "8.1.28" +load(pathJoin("stack-cray-mpich", stack_cray_mpich_ver)) + +cmake_ver=os.getenv("cmake_ver") or "3.23.1" +load(pathJoin("cmake", cmake_ver)) + +load("upp_common") + +unload("darshan-runtime") +unload("cray-libsci") + +setenv("CC","cc") +setenv("CXX","CC") +setenv("FC","ftn") + +setenv("CMAKE_Platform","gaeac6.intel") diff --git a/tests/compile_upp.sh b/tests/compile_upp.sh index bce87b787..64f0c5434 100755 --- a/tests/compile_upp.sh +++ b/tests/compile_upp.sh @@ -8,38 +8,51 @@ set -eu usage() { echo - echo "Usage: $0 [-p] [-g] [-w] [-v] [-c] [-i] [-d] -h" + echo "Usage: $0 [options]" echo echo " -p installation prefix DEFAULT: ../install" echo " -g build with GTG(users with gtg repos. access only) DEFAULT: OFF" - echo " -I build with libIFI(users with ifi repos. access only) DEFAULT: OFF" echo " -i build with libIFI(users with ifi install access only) DEFAULT: OFF" + echo " -I build with libIFI (users with ifi repos. access only) DEFAULT: OFF" + echo " -B build libIFI test programs (only valid with -I) DEFAULT: OFF" echo " -n build without nemsio DEFAULT: ON" echo " -w build without WRF-IO DEFAULT: ON" echo " -v build with cmake verbose DEFAULT: NO" echo " -c Compiler to use for build DEFAULT: intel" echo " -d Debug mode of CMAKE_BUILD_TYPE DEFAULT: Release" + echo " -Doption=value Passes this option to cmake (can use more than once)" echo " -h display this message and quit" echo exit 1 } +load_ifi_module=NO prefix="../install" ifi_opt=" -DBUILD_WITH_IFI=OFF" +build_ifi_executables_opt=" " +build_ifi_executables=NO gtg_opt=" -DBUILD_WITH_GTG=OFF" nemsio_opt=" -DBUILD_WITH_NEMSIO=ON" wrfio_opt=" -DBUILD_WITH_WRFIO=ON" +more=" " compiler="intel" verbose_opt="" debug_opt="" -while getopts ":p:gnwc:vhiId" opt; do +while getopts ":p:gnwc:vhiIdBD:" opt; do case $opt in + D) + more="$more -$opt$OPTARG" + ;; p) prefix=$OPTARG ;; g) gtg_opt=" -DBUILD_WITH_GTG=ON" ;; + B) + build_ifi_executables_opt=" -DBUILD_IFI_EXECUTABLES=ON" + build_ifi_executables=YES + ;; n) nemsio_opt=" -DBUILD_WITH_NEMSIO=OFF" ;; @@ -51,6 +64,7 @@ while getopts ":p:gnwc:vhiId" opt; do ;; i) ifi_opt=" -DREQUIRE_IFI=ON" + load_ifi_module=YES ;; c) compiler=$OPTARG @@ -74,7 +88,7 @@ if [[ ! -z $debug_opt && $ifi_opt =~ INTERNAL.*=ON ]] ; then debug_opt="$debug_opt -DIFI_DEBUG=ON" fi -cmake_opts=" -DCMAKE_INSTALL_PREFIX=$prefix"${nemsio_opt}${wrfio_opt}${gtg_opt}${ifi_opt}${debug_opt} +cmake_opts=" -DCMAKE_INSTALL_PREFIX=$prefix"${nemsio_opt}${wrfio_opt}${gtg_opt}${ifi_opt}${debug_opt}${build_ifi_executables_opt}${more} if [[ $(uname -s) == Darwin ]]; then readonly MYDIR=$(cd "$(dirname "$(greadlink -f -n "${BASH_SOURCE[0]}" )" )" && pwd -P) @@ -110,6 +124,14 @@ if [[ $MACHINE_ID != "unknown" ]]; then exit 1 fi module load $modulefile + if [[ "$load_ifi_module" == YES ]] ; then + echo "Loading modulefile for external libIFI library" + module load ${modulefile}_external_ifi + fi + if [[ "$build_ifi_executables" == YES ]] ; then + echo "Loading libIFI executables' prerequisites" + module load ${modulefile}_ifi_test_prereqs + fi module list fi @@ -123,3 +145,6 @@ make install rm -rf $PATHTR/exec && mkdir -p $PATHTR/exec cp $prefix/bin/upp.x $PATHTR/exec/. +if [[ "$build_ifi_executables" == YES ]] ; then + cp $prefix/bin/fip2-lookalike.x $PATHTR/exec/. +fi From 56a38de50668d80e4d040f925bf7469e88fdefcd Mon Sep 17 00:00:00 2001 From: DavidBurrows-NCO Date: Fri, 18 Oct 2024 11:20:51 -0400 Subject: [PATCH 3/3] add c6 to detect_machine.sh --- tests/detect_machine.sh | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) diff --git a/tests/detect_machine.sh b/tests/detect_machine.sh index 5e1187bde..807026e07 100755 --- a/tests/detect_machine.sh +++ b/tests/detect_machine.sh @@ -21,8 +21,11 @@ case $(hostname -f) in dlogin0[1-9].dogwood.wcoss2.ncep.noaa.gov) MACHINE_ID=wcoss2 ;; ### dogwood01-9 dlogin10.dogwood.wcoss2.ncep.noaa.gov) MACHINE_ID=wcoss2 ;; ### dogwood10 - gaea5[1-8]) MACHINE_ID=gaea ;; ### gaea51-58 - gaea5[1-8].ncrc.gov) MACHINE_ID=gaea ;; ### gaea51-58 + gaea5[1-8]) MACHINE_ID=gaeac5 ;; ### gaea51-58 + gaea5[1-8].ncrc.gov) MACHINE_ID=gaeac5 ;; ### gaea51-58 + + gaea6[1-8]) MACHINE_ID=gaeac6 ;; ### gaea61-68 + gaea6[1-8].ncrc.gov) MACHINE_ID=gaeac6 ;; ### gaea61-68 hfe0[1-9]) MACHINE_ID=hera ;; ### hera01-09 hfe1[01]) MACHINE_ID=hera ;; ### hera10-11 @@ -84,9 +87,12 @@ elif [[ -d /work ]]; then else MACHINE_ID=orion fi -elif [[ -d /gpfs && -d /ncrc ]]; then - # We are on GAEA. - MACHINE_ID=gaea +elif [[ -d /gpfs/f5 ]]; then + # We are on GAEA-C5. + MACHINE_ID=gaeac5 +elif [[ -d /gpfs/f6 ]]; then + # We are on GAEA-C6. + MACHINE_ID=gaeac6 elif [[ -d /data/prod ]]; then # We are on SSEC's S4 MACHINE_ID=s4