forked from ecmwf-ifs/dwarf-p-cloudsc
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add arch files for nvhpc/22.7 @ MLux.
- Loading branch information
Showing
2 changed files
with
109 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
# (C) Copyright 1988- ECMWF. | ||
# | ||
# This software is licensed under the terms of the Apache Licence Version 2.0 | ||
# which can be obtained at http://www.apache.org/licenses/LICENSE-2.0. | ||
# In applying this licence, ECMWF does not waive the privileges and immunities | ||
# granted to it by virtue of its status as an intergovernmental organisation | ||
# nor does it submit to any jurisdiction. | ||
|
||
# Source me to get the correct configure/build/run environment | ||
|
||
# Store tracing and disable (module is *way* too verbose) | ||
{ tracing_=${-//[^x]/}; set +x; } 2>/dev/null | ||
|
||
module_load() { | ||
echo "+ module load $1" | ||
module load $1 | ||
} | ||
module_unload() { | ||
echo "+ module unload $1" | ||
module unload $1 | ||
} | ||
|
||
# Unload all modules to be certain | ||
module --force purge | ||
|
||
# Load modules | ||
module_load env/release/2022.1 | ||
module_load CUDA/11.7.0 | ||
module_load NVHPC/22.7-CUDA-11.7.0 | ||
module_load OpenMPI/4.1.4-GCC-11.3.0 | ||
module_load CMake | ||
module_load Boost | ||
module_load Python | ||
#module_load HDF5 | ||
|
||
export CC=nvc | ||
export CXX=nvc++ | ||
export F77=nvfortran | ||
export FC=nvfortran | ||
export F90=nvfortran | ||
|
||
export HDF5_ROOT=/project/home/p200177/nasu/hdf5/1.14.3/build/release/2022.1/nvhpc/22.7/ | ||
|
||
# Increase stack size to maximum | ||
ulimit -S -s unlimited | ||
|
||
set -x | ||
|
||
# Restore tracing to stored setting | ||
{ if [[ -n "$tracing_" ]]; then set -x; else set +x; fi } 2>/dev/null | ||
|
||
export ECBUILD_TOOLCHAIN="./toolchain.cmake" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,57 @@ | ||
# (C) Copyright 1988- ECMWF. | ||
# | ||
# This software is licensed under the terms of the Apache Licence Version 2.0 | ||
# which can be obtained at http://www.apache.org/licenses/LICENSE-2.0. | ||
# In applying this licence, ECMWF does not waive the privileges and immunities | ||
# granted to it by virtue of its status as an intergovernmental organisation | ||
# nor does it submit to any jurisdiction. | ||
|
||
#################################################################### | ||
# COMPILER | ||
#################################################################### | ||
|
||
set( ECBUILD_FIND_MPI ON ) | ||
|
||
#################################################################### | ||
# OpenMP FLAGS | ||
#################################################################### | ||
|
||
# Note: OpenMP_Fortran_FLAGS gets overwritten by the FindOpenMP module | ||
# unless its stored as a cache variable | ||
set( OpenMP_Fortran_FLAGS "-mp -mp=gpu,bind,allcores,numa" CACHE STRING "" ) | ||
|
||
# Note: OpenMP_C_FLAGS and OpenMP_C_LIB_NAMES have to be provided _both_ to | ||
# keep FindOpenMP from overwriting the FLAGS variable (the cache entry alone | ||
# doesn't have any effect here as the module uses FORCE to overwrite the | ||
# existing value) | ||
set( OpenMP_C_FLAGS "-mp -mp=bind,allcores,numa" CACHE STRING "" ) | ||
set( OpenMP_C_LIB_NAMES "acchost" CACHE STRING "") | ||
|
||
#################################################################### | ||
# OpenAcc FLAGS | ||
#################################################################### | ||
|
||
# NB: We have to add `-mp` again to avoid undefined symbols during linking | ||
# (smells like an Nvidia bug) | ||
set( OpenACC_Fortran_FLAGS "-acc=gpu -mp=gpu -gpu=cc80,lineinfo,fastmath" CACHE STRING "" ) | ||
# Enable this to get more detailed compiler output | ||
# set( OpenACC_Fortran_FLAGS "${OpenACC_Fortran_FLAGS} -Minfo" ) | ||
|
||
#################################################################### | ||
# COMMON FLAGS | ||
#################################################################### | ||
|
||
set(ECBUILD_Fortran_FLAGS "-fpic") | ||
set(ECBUILD_Fortran_FLAGS "${ECBUILD_Fortran_FLAGS} -Mframe") | ||
set(ECBUILD_Fortran_FLAGS "${ECBUILD_Fortran_FLAGS} -Mbyteswapio") | ||
set(ECBUILD_Fortran_FLAGS "${ECBUILD_Fortran_FLAGS} -Mstack_arrays") | ||
set(ECBUILD_Fortran_FLAGS "${ECBUILD_Fortran_FLAGS} -Mrecursive") | ||
set(ECBUILD_Fortran_FLAGS "${ECBUILD_Fortran_FLAGS} -Ktrap=fp") | ||
set(ECBUILD_Fortran_FLAGS "${ECBUILD_Fortran_FLAGS} -Kieee") | ||
set(ECBUILD_Fortran_FLAGS "${ECBUILD_Fortran_FLAGS} -Mdaz") | ||
|
||
set( ECBUILD_Fortran_FLAGS_BIT "-O2 -gopt" ) | ||
|
||
set( ECBUILD_C_FLAGS "-O2 -gopt -traceback" ) | ||
|
||
set( ECBUILD_CXX_FLAGS "-O2 -gopt" ) |