| 1 |
#!/bin/bash |
| 2 |
|
| 3 |
# This script expects testbed (not SEMS!) modules to be loaded already. |
| 4 |
|
| 5 |
#Set path to Trilinos: |
| 6 |
TRILINOS_PATH=${HOME}/Trilinos2 |
| 7 |
|
| 8 |
# You could load a devpack here, but for now assume it was loaded. |
| 9 |
# module load devpack |
| 10 |
|
| 11 |
# Set up backends for Trilinos |
| 12 |
export CUDA=OFF |
| 13 |
export OPENMP=OFF |
| 14 |
export PTHREAD=OFF |
| 15 |
export SERIAL=ON |
| 16 |
export COMPLEX=OFF |
| 17 |
|
| 18 |
# Set up Architecture |
| 19 |
|
| 20 |
# If you want Intel Sandy Bridge or Ivy Bridge, uncomment the lines |
| 21 |
# below (up to but not including "Intel Haswell"), if they are not |
| 22 |
# already uncommented. (This one has not yet been tested. All the |
| 23 |
# others have been tested.) |
| 24 |
|
| 25 |
#Intel SandyBridge / IvyBridge |
| 26 |
export ARCH_CXX_FLAG="-mavx" |
| 27 |
export ARCH_C_FLAG="-mavx" |
| 28 |
export BLAS_LIBRARIES="-lblas" |
| 29 |
export LAPACK_LIBRARIES="-llapack" |
| 30 |
|
| 31 |
# If you want Intel Haswell, uncomment the lines below (up to but not |
| 32 |
# including "Intel KNL"), if they are not already uncommented. |
| 33 |
|
| 34 |
#Intel Haswell |
| 35 |
#export ARCH_CXX_FLAG="-xCORE-AVX2 -mkl" |
| 36 |
#export ARCH_C_FLAG="-xCORE-AVX2 -mkl" |
| 37 |
#export BLAS_LIBRARIES="-mkl;${MKLROOT}/lib/intel64/libmkl_intel_lp64.a;${MKLROOT}/lib/intel64/libmkl_intel_thread.a;${MKLROOT}/lib/intel64/libmkl_core.a" |
| 38 |
#export LAPACK_LIBRARIES=${BLAS_LIBRARIES} |
| 39 |
|
| 40 |
# If you want KNL, uncomment the lines below (up to but not including |
| 41 |
# "IBM Power8"), if they are not already uncommented. |
| 42 |
|
| 43 |
#Intel KNL |
| 44 |
#export ARCH_CXX_FLAG="-xMIC-AVX512 -mkl" |
| 45 |
#export ARCH_C_FLAG="-xMIC-AVX512 -mkl" |
| 46 |
#export BLAS_LIBRARIES="-mkl;${MKLROOT}/lib/mic/libmkl_intel_lp64.a;${MKLROOT}/lib/mic/libmkl_intel_thread.a;${MKLROOT}/lib/mic/libmkl_core.a" |
| 47 |
#export LAPACK_LIBRARIES=${BLAS_LIBRARIES} |
| 48 |
|
| 49 |
# If you want IBM Power8 withOUT GPUs, uncomment the lines below (up |
| 50 |
# to but not including "IBM Power8 + NVIDIA K80"), if they are not |
| 51 |
# already uncommented. |
| 52 |
|
| 53 |
#IBM Power8: |
| 54 |
#export ARCH_CXX_FLAG="-mcpu=power8" |
| 55 |
#export ARCH_C_FLAG="-mcpu=power8" |
| 56 |
#export BLAS_LIBRARIES="${BLAS_ROOT}/lib/libblas.a;gfortran;gomp" |
| 57 |
#export LAPACK_LIBRARIES="${LAPACK_ROOT}/lib/liblapack.a;gfortran;gomp" |
| 58 |
|
| 59 |
# If you want IBM Power8 with K80 GPUs, uncomment the lines below (up |
| 60 |
# to but not including "IBM Power8 + NVIDIA P100"), if they are not |
| 61 |
# already uncommented. |
| 62 |
|
| 63 |
#IBM Power8 + NVIDIA K80 |
| 64 |
#export OMPI_CXX=${TRILINOS_PATH}/packages/kokkos/bin/nvcc_wrapper |
| 65 |
#export ARCH_CXX_FLAG="-mcpu=power8 -arch=sm_37" |
| 66 |
#export ARCH_C_FLAG="-mcpu=power8" |
| 67 |
#export BLAS_LIBRARIES="${BLAS_ROOT}/lib/libblas.a;gfortran;gomp" |
| 68 |
#export LAPACK_LIBRARIES="${LAPACK_ROOT}/lib/liblapack.a;gfortran;gomp" |
| 69 |
|
| 70 |
# If you want IBM Power8 with P100 GPUs, uncomment the lines below (up |
| 71 |
# to but not including "Set up Tests/Examples"), if they are not |
| 72 |
# already uncommented. |
| 73 |
|
| 74 |
#IBM Power8 + NVIDIA P100 |
| 75 |
#export OMPI_CXX=${TRILINOS_PATH}/packages/kokkos/bin/nvcc_wrapper |
| 76 |
#export ARCH_CXX_FLAG="-mcpu=power8 -arch=sm_60" |
| 77 |
#export ARCH_C_FLAG="-mcpu=power8" |
| 78 |
#export BLAS_LIBRARIES="${BLAS_ROOT}/lib/libblas.a;gfortran;gomp" |
| 79 |
#export LAPACK_LIBRARIES="${LAPACK_ROOT}/lib/liblapack.a;gfortran;gomp" |
| 80 |
|
| 81 |
|
| 82 |
# Set up Tests/Examples |
| 83 |
|
| 84 |
export TESTS=ON |
| 85 |
export EXAMPLES=ON |
| 86 |
|
| 87 |
|
| 88 |
# Set up number of OpenMP Threads: |
| 89 |
|
| 90 |
export OMP_NUM_THREADS=8 |
| 91 |
|
| 92 |
|
| 93 |
|
| 94 |
############################################### |
| 95 |
############################################### |
| 96 |
# Don't change things below |
| 97 |
############################################### |
| 98 |
############################################### |
| 99 |
|
| 100 |
# This sets Jenkins-related environment variables. It's for the |
| 101 |
# script below, which expects those environment variables to be set, |
| 102 |
# even if not running Jenkins. |
| 103 |
|
| 104 |
export JENKINS_DO_CUDA=${CUDA} |
| 105 |
export JENKINS_DO_OPENMP=${OPENMP} |
| 106 |
export JENKINS_DO_PTHREAD=${PTHREAD} |
| 107 |
export JENKINS_DO_SERIAL=${SERIAL} |
| 108 |
export JENKINS_DO_COMPLEX=${COMPLEX} |
| 109 |
|
| 110 |
export JENKINS_ARCH_CXX_FLAG=${ARCH_CXX_FLAG} |
| 111 |
export JENKINS_ARCH_C_FLAG=${ARCH_C_FLAG} |
| 112 |
|
| 113 |
export JENKINS_DO_TESTS=${TESTS} |
| 114 |
export JENKINS_DO_EXAMPLES=${EXAMPLES} |
| 115 |
|
| 116 |
# This actually runs CMake. |
| 117 |
|
| 118 |
source ${TRILINOS_PATH}/sampleScripts/Sandia-SEMS/configure-sems-jenkins-all |
| 119 |
|