-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #67 from ecmwf-ifs/naan-cce17
Add CPU only support for CCE17
- Loading branch information
Showing
12 changed files
with
206 additions
and
22 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
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
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,71 @@ | ||
# (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 to be certain | ||
module reset | ||
|
||
# Load modules | ||
module_load LUMI/24.03 | ||
module_load partition/G | ||
module_load PrgEnv-cray/8.4.0 | ||
module_load cce/17.0.1 | ||
# module_load cray-mpich/8.1.27 | ||
module_load cray-mpich/8.1.29 | ||
module_load craype-network-ofi | ||
module_load rocm/6.0.3 | ||
module_load buildtools/24.03 | ||
# module_load Boost/1.82.0-cpeCray-23.09 | ||
module_load cray-libsci/24.03.0 | ||
module_load Boost/1.83.0-cpeCray-24.03 | ||
module_load cray-python/3.10.10 | ||
module_load craype-x86-trento | ||
module_load craype-accel-amd-gfx90a | ||
|
||
### Handling of "magic" cray modules | ||
# 1) Load the cray modules | ||
# module_load cray-hdf5/1.12.2.7 | ||
module_load cray-hdf5/1.12.2.11 | ||
# 2) Store variables to locate the packages | ||
_HDF5_ROOT=${CRAY_HDF5_PREFIX} | ||
# 3) Unload the cray modules in reverse order, removing all the magic | ||
module_unload cray-hdf5 | ||
# 4) Define variables that CMake introspects | ||
export HDF5_ROOT=${_HDF5_ROOT} | ||
|
||
# Export environment variable3s | ||
export MPI_HOME=${MPICH_DIR} | ||
export CC=cc | ||
export CXX=CC | ||
export FC=ftn | ||
export HIPCXX=$(hipconfig --hipclangpath)/clang++ | ||
|
||
module list | ||
|
||
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" | ||
path=$BASH_SOURCE | ||
DIR_PATH=$(dirname $path) | ||
export ECBUILD_TOOLCHAIN=$DIR_PATH/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,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. | ||
|
||
#################################################################### | ||
# COMPILER | ||
#################################################################### | ||
|
||
set( ECBUILD_FIND_MPI OFF ) | ||
set( ENABLE_USE_STMT_FUNC ON CACHE STRING "" ) | ||
|
||
#################################################################### | ||
# OpenMP FLAGS | ||
#################################################################### | ||
|
||
set( OpenMP_C_FLAGS "-fopenmp" CACHE STRING "" ) | ||
set( OpenMP_CXX_FLAGS "-fopenmp" CACHE STRING "" ) | ||
set( OpenMP_Fortran_FLAGS "-homp -hlist=aimd" CACHE STRING "" ) | ||
set( OpenMP_C_LIB_NAMES "craymp" CACHE STRING "" ) | ||
set( OpenMP_CXX_LIB_NAMES "craymp" CACHE STRING "" ) | ||
set( OpenMP_Fortran_LIB_NAMES "craymp" CACHE STRING "" ) | ||
set( OpenMP_craymp_LIBRARY "/opt/cray/pe/cce/17.0.1/cce/x86_64/lib/libcraymp.so" CACHE STRING "" ) | ||
|
||
#################################################################### | ||
# OpenACC FLAGS | ||
#################################################################### | ||
|
||
set( OpenACC_C_FLAGS "-hacc" CACHE STRING "" ) | ||
# set( OpenACC_CXX_FLAGS "-hacc" CACHE STRING "" ) | ||
# set( OpenACC_Fortran_FLAGS "-hacc" CACHE STRING "" ) | ||
|
||
#################################################################### | ||
# Compiler FLAGS | ||
#################################################################### | ||
|
||
# General Flags (add to default) | ||
set(ECBUILD_Fortran_FLAGS "-h acc_model=auto_async_none") | ||
set(ECBUILD_Fortran_FLAGS "${ECBUILD_Fortran_FLAGS} -hbyteswapio") | ||
set(ECBUILD_Fortran_FLAGS "${ECBUILD_Fortran_FLAGS} -Wl, --as-needed") | ||
|
||
set(ECBUILD_Fortran_FLAGS_BIT "-O3 -hfp1 -hscalar3 -hvector3 -G2 -haggress -DNDEBUG") | ||
|
||
if(NOT DEFINED CMAKE_HIP_ARCHITECTURES) | ||
set(CMAKE_HIP_ARCHITECTURES gfx90a) | ||
endif() | ||
|
||
# select OpenMP pragma to be used | ||
# set( HAVE_OMP_TARGET_LOOP_CONSTRUCT_BIND_PARALLEL OFF CACHE BOOL "" ) |
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
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
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
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
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
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
Oops, something went wrong.