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

Diff of /MITgcm/tools/build_options/linux_ia32_g77

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

revision 1.28 by jmc, Tue Sep 6 22:13:26 2011 UTC revision 1.30 by jmc, Mon Jul 22 18:40:45 2013 UTC
# Line 28  NOOPTFILES='' Line 28  NOOPTFILES=''
28    
29  has_sse2=f  has_sse2=f
30  grep flags /proc/cpuinfo | grep sse2 > /dev/null 2>&1  &&  has_sse2=t  grep flags /proc/cpuinfo | grep sse2 > /dev/null 2>&1  &&  has_sse2=t
31  if test "x$has_sse2" = xt ; then  
32      FFLAGS="$FFLAGS -Wimplicit -Wunused -mfpmath=sse -msse -msse2"  FFLAGS="$FFLAGS -Wimplicit -Wunused"
 else  
     FFLAGS="$FFLAGS -Wimplicit -Wunused -ffloat-store"  
 fi  
33    
34  if test "x$IEEE" = x ; then     #- with optimisation:  if test "x$IEEE" = x ; then     #- with optimisation:
35       #- note(jmc): on aces, sse & sse2 are faster; -O3 is not always faster than -O2
36        if test "x$has_sse2" = xt ; then
37            FFLAGS="$FFLAGS -mfpmath=sse -msse -msse2"
38        fi
39     #FOPTIM='-O3 -malign-double -funroll-loops'     #FOPTIM='-O3 -malign-double -funroll-loops'
40  #- note(jmc):     # Problems with "-funroll-loops" for some set-up, e.g. tutorial_held_suarez_cs
 # -O3 is not always faster than -O2 ; sse & sse2 are faster ;  
 # Problems with "-funroll-loops" for some set-up, e.g. tutorial_held_suarez_cs  
41      FOPTIM='-O3 -malign-double'      FOPTIM='-O3 -malign-double'
42  else                            #- no optimisation + IEEE :  else                            #- no optimisation + IEEE :
43        if test "x$has_sse2" = xt ; then
44            FFLAGS="$FFLAGS -mfpmath=sse -msse -msse2"
45        else
46            FFLAGS="$FFLAGS -ffloat-store"
47        fi
48      FOPTIM='-O0 -malign-double'      FOPTIM='-O0 -malign-double'
49  fi  fi
50    
# Line 73  fi Line 77  fi
77  if [ -n "$MPI_INC_DIR" -a "x$MPI" = xtrue ] ; then  if [ -n "$MPI_INC_DIR" -a "x$MPI" = xtrue ] ; then
78      INCLUDES="$INCLUDES -I$MPI_INC_DIR"      INCLUDES="$INCLUDES -I$MPI_INC_DIR"
79      INCLUDEDIRS="$INCLUDEDIRS $MPI_INC_DIR"      INCLUDEDIRS="$INCLUDEDIRS $MPI_INC_DIR"
80  #   MPIINCLUDEDIR="$MPI_INC_DIR"      #- used for parallel (MPI) DIVA
81  #   MPI_HEADER_FILES='mpif.h mpiof.h'      MPIINCLUDEDIR="$MPI_INC_DIR"
82  #   MPI_HEADER_FILES_INC='./mpi_headers/mpif.h ./mpi_headers/mpiof.h'     #MPI_HEADER_FILES='mpif.h mpiof.h'
83  fi  fi

Legend:
Removed from v.1.28  
changed lines
  Added in v.1.30

  ViewVC Help
Powered by ViewVC 1.1.22