1 |
jmc |
1.1 |
#!/bin/bash |
2 |
|
|
# |
3 |
jmc |
1.4 |
# $Header: /u/gcmpack/MITgcm/tools/build_options/linux_ia32_ifort.v9+mth,v 1.3 2006/08/31 13:51:19 jmc Exp $ |
4 |
jmc |
1.1 |
# $Name: $ |
5 |
|
|
# |
6 |
|
|
# jmc: copied from linux_ia32_ifort+authors_v9 |
7 |
|
|
# and added openmp stuff to run multi-threaded |
8 |
jmc |
1.4 |
# to run, needs to set environment var. OMP_NUM_THREADS |
9 |
|
|
# and generally, needs to increase the stack-size: |
10 |
|
|
# - sh,bash: |
11 |
|
|
# > export OMP_NUM_THREADS=2 |
12 |
|
|
# > export KMP_STACKSIZE=400m |
13 |
|
|
# - csh,tcsh: |
14 |
|
|
# > setenv OMP_NUM_THREADS 2 |
15 |
|
|
# > setenv KMP_STACKSIZE 400m |
16 |
|
|
#------- |
17 |
jmc |
1.1 |
# |
18 |
|
|
# tested on hugo (FC.4), eddy (FC.5): 20060713 |
19 |
|
|
# |
20 |
|
|
# Build options for the intel 9.0 fortran compiler |
21 |
|
|
# ph: use ifort compiler options -convert big_endian -assume byterecl |
22 |
|
|
|
23 |
|
|
FC=/usr/local/pkg/intel/intel_fc_90/bin/ifort |
24 |
|
|
F90C=/usr/local/pkg/intel/intel_fc_90/bin/ifort |
25 |
|
|
F90FIXEDFORMAT='-fixed -Tf' |
26 |
|
|
DEFINES='-DWORDLENGTH=4 -DUSE_OMP_THREADING' |
27 |
|
|
LINK='/usr/local/pkg/intel/intel_fc_90/bin/ifort -i-static -no-ipo' |
28 |
|
|
CPP='cpp -traditional -P' |
29 |
jmc |
1.2 |
INCLUDES='-I/usr/local/pkg/netcdf/netcdf-3.5.1/include' |
30 |
jmc |
1.1 |
|
31 |
|
|
# Note that the -mp switch is for ieee "maintain precision" and is |
32 |
|
|
# roughly equivalent to -ieee |
33 |
|
|
if test "x$IEEE" = x ; then |
34 |
|
|
FOPTIM='-O3 -align' |
35 |
|
|
#P3 FOPTIM=$FOPTIM' -tpp6 -xWKM' |
36 |
|
|
#P4 FOPTIM=$FOPTIM' -tpp7 -xWKM' |
37 |
|
|
FFLAGS='-132 -r8 -i4 -w95 -W0 -WB -convert big_endian -assume byterecl' |
38 |
|
|
F90FLAGS='-r8 -i4 -w95 -W0 -WB -openmp -convert big_endian -assume byterecl' |
39 |
|
|
else |
40 |
jmc |
1.3 |
FOPTIM='-O0 -noalign -check all' |
41 |
jmc |
1.1 |
FFLAGS='-132 -r8 -i4 -w95 -W0 -WB -openmp -xN -pc64 -convert big_endian -assume byterecl' |
42 |
|
|
#FFLAGS='-mp -132 -r8 -i4 -w95 -W0 -WB' |
43 |
|
|
fi |
44 |
|
|
|