/[MITgcm]/MITgcm/tools/build_options/linux_amd64_ifort_beagle
ViewVC logotype

Annotation of /MITgcm/tools/build_options/linux_amd64_ifort_beagle

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.5 - (hide annotations) (download)
Fri Aug 12 23:09:08 2011 UTC (12 years, 9 months ago) by jmc
Branch: MAIN
CVS Tags: checkpoint63b
Changes since 1.4: +2 -1 lines
specify GET_FC_VERSION to get compiler version in genmake.log

1 jahn 1.1 #!/bin/bash
2     #
3 jmc 1.5 # $Header: /u/gcmpack/MITgcm/tools/build_options/linux_amd64_ifort_beagle,v 1.4 2010/03/21 17:59:54 jmc Exp $
4 jmc 1.2 # $Name: $
5 jahn 1.1 #
6     # These are the build options used with the Intel 10.x compiler for
7     # testing on Beagle without mpi.
8     #
9     # Use after
10     #
11     # module add darwin
12     # module add mitgcm
13     #
14     # (tested with darwin/20090605 mitgcm/20090605, i.e.,
15     # intel/10.0.025 mx/1.0 netcdf/3.6.2/intel-10.0.025 mpich-mx/1.2.7..7/intel-10.0.025)
16     #
17     # These modules set FFLAGS, CFLAGS and CPPFLAGS for mpich and netcdf.
18     #
19     # The SGE -V option for exporting environment variables may also be
20     # helpful if you encounter missing-library problems. Or,
21     # alternatively, one may choose to link with one of the intel
22     # "-static" or "-i-static" flags.
23    
24     FC='ifort'
25     CC='icc'
26     #F90C='mpif90 -fixed -c '
27     LINK='ifort'
28     # the netcdf module sets CPPFLAGS, LDFLAGS and FFLAGS
29     INCLUDES="$CPPFLAGS"
30     # -shared-intel needed with netcdf (namespace conflict???)
31     LIBS="$LDFLAGS -shared-intel"
32    
33     # -DIFORT turns on ifort-specific declarations in darwin (RAND is not an intrinsic)
34     DEFINES='-DWORDLENGTH=4 -DIFORT'
35     CPP='cpp -traditional -P'
36 jmc 1.2 EXTENDED_SRC_FLAG='-132'
37 jmc 1.5 GET_FC_VERSION="--version"
38 jmc 1.2 #OMPFLAG='-openmp'
39 jahn 1.1
40 jmc 1.2 NOOPTFILES='mds_byteswapr8.F mds_byteswapr4.F mds_byteswapi4.F mom_calc_ke.F mon_ke.F'
41 jahn 1.1
42     if test "x$IEEE" = x ; then
43     # No need for IEEE-754
44     NOOPTFLAGS='-O2'
45 jahn 1.3 # use this for exact checkpointing (slightly slower):
46     # FOPTIM='-O2 -pc64 -mieee-fp -align'
47     FOPTIM='-O2 -align'
48 jahn 1.1 # ifort options:
49     # -132 fixed-form line length is 132 characters
50     # -r8 REAL is REAL*8
51     # -i4 INTEGER is INTEGER*4
52     # -w95 don't warn about use of Fortran 95 extensions
53     # -W0 disable all warning messages
54     # -WB turns a compile-time bounds check error into a warning
55     # -xT optimize for Intel Core2 and Xeon 51xx
56     # -fno-alias don't assume aliasing (assume that different variables DON'T refer to the same memory location)
57     # -assume byterecl record length in OPEN statements is in bytes
58     # -convert big_endian binary files contain big-endian data
59 jmc 1.4 FFLAGS="$FFLAGS -w95 -W0 -WB -xT -fno-alias -assume byterecl -convert big_endian"
60 jahn 1.1 else
61     # Try to follow IEEE-754
62     NOOPTFLAGS='-O0'
63     # FOPTIM='-O0 -noalign -CA -CB -CU -CV -CS'
64     FOPTIM='-O0 -noalign'
65     # -pc64 round floating point values to 64 bits
66     # one could also try
67     # -mp maintain precision
68 jmc 1.4 FFLAGS="$FFLAGS -pc64 -w95 -W0 -WB -xT -fno-alias -assume byterecl -convert big_endian"
69 jahn 1.1 fi
70 jmc 1.4 #- might want to use '-r8' for fizhi pkg:
71     #FFLAGS="$FFLAGS -r8"
72    
73 jahn 1.1 #F90FLAGS=$FFLAGS
74     #F90OPTIM=$FOPTIM
75    
76 jmc 1.2 NOOPTFILES=$NOOPTFILES' mds_byteswap.F'
77 jahn 1.1

  ViewVC Help
Powered by ViewVC 1.1.22