-
Notifications
You must be signed in to change notification settings - Fork 1
/
20_CURIE.conf
91 lines (76 loc) · 2.91 KB
/
20_CURIE.conf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
#! /bin/bash
shopt -s expand_aliases
STEP0(){
LIST_MACHINE="$LIST_MACHINE CURIE"
}
# Sets some vars
# If system version of a package is available use it
STEP1(){
if [ "$MACHINE" = "CURIE" ]; then
COMP="ICC" #MANDATORY
OPENMPI="SYS"; VERSION_OPENMPI="1.2.7.2"
HDF5="SYS"; VERSION_HDF5="1.8.12"
CGNS="SYS"; VERSION_CGNS="3.1.3"
SCOTCH="NONE"; VERSION_SCOTCH="NONE" # BUGGY
# SCOTCH="SYS"; VERSION_SCOTCH="5.1.12b" # BUGGY
# METIS="SYS"; VERSION_METIS="4.0.1" # NOT USABLE
DOWN="NO"
fi
}
# Sets some vars
# And prepare the environment
# Only module load and exports are mandatory
STEP2(){
if [ "$MACHINE" = "CURIE" ]; then
module purge > /dev/null 2>&1
module load cmake/2.8.9
[[ "$COMP" = "ICC" ]] && module load intel/14.0.3.174
module load mkl/14.0.3.174
[[ "$OPENMPI" = "SYS" ]] && module load "mpi/bullxmpi/$VERSION_OPENMPI"
[[ "$SCOTCH" = "SYS" ]] && module load "ptscotch/$VERSION_SCOTCH"
[[ "$HDF5" = "SYS" ]] && module load "hdf5/$VERSION_HDF5"
[[ "$CGNS" = "SYS" ]] && module load "cgns/$VERSION_CGNS"
[[ "$METIS" = "SYS" ]] && module load "metis/$VERSION_METIS"
export CPATH="$MKL_INCDIR:$CPATH"
[[ "$SCOTCH" = "SYS" ]] && export CPATH="$SCOTCH_ROOT/include/:$CPATH"
[[ "$HDF5" = "SYS" ]] && export CPATH="$HDF5_ROOT/include/:$CPATH"
[[ "$OPENMPI" = "SYS" ]] && BIN_OPENMPI="$MPI_ROOT"
[[ "$SCOTCH" = "SYS" ]] && BIN_SCOTCH="$SCOTCH_ROOT"
[[ "$HDF5" = "SYS" ]] && BIN_HDF5="$HDF5_ROOT"
[[ "$CGNS" = "SYS" ]] && BIN_CGNS="$CGNS_ROOT"
[[ "$METIS" = "SYS" ]] && BIN_METIS="$METIS_ROOT"
EXTRA_CONF="$EXTRA_CONF --with-modules=no" # extra configure option to code saturne
EXTRA_CONF="$EXTRA_CONF --with-blas-type=MKL"
fi
}
#======================================================== Compilators
#============================================================ Options
STEP3(){
if [ "$MACHINE" = "CURIE" ]; then
FLAGS_OPTIM="$FLAGS_OPTIM -O2" #fail to compile scotch with O3
fi
}
STEP9(){
if [ "$MACHINE" = "CURIE" ]; then
echo
echo -e "\e[31m\e[1m**** Other instructions ****\e[21m\e[0m"
echo "To use code_saturne in interactive mode"
echo "You have to execute that before:"
echo "ccc_mprun -p standard -n 8 -T 3600 -K"
echo
echo "For batch mode, you have to tell code_saturne to use CCC system."
echo "In order to do that, use $BIN_SATURNE/etc/code_saturne.cfg"
echo "You will have to modify the runcase file to add"
echo "#MSUB -q standard"
echo "module load intel/14.0.1.106"
echo "module load mpi/bullxmpi/$VERSION_OPENMPI"
echo "module load ptscotch/$VERSION_SCOTCH"
echo "module load hdf5/$VERSION_HDF5"
echo "module load cgns/$VERSION_CGNS"
echo "module load metis/$VERSION_METIS"
echo "module load mpiprofile/bullxmpi/performance"
echo "export OMP_NUM_THREADS=1"
echo
fi
}
"STEP$1" 2>/dev/null