[mpich-discuss] F90FLAGS "-i4" statement for mpich2 configuration

Pavan Balaji balaji at mcs.anl.gov
Thu Apr 29 07:22:43 CDT 2010


You can pass F90FLAGS to configure using:

% ./configure --prefix=/opt/mpich2 F90FLAGS=-i4

Alternatively, you can use gfortran as your F90 compiler as well (this 
is preferred):

% ./configure --prefix=/opt/mpich2 F77=gfortran F90=gfortran

  -- Pavan

On 04/29/2010 06:38 AM, Steenhauer, Kate wrote:
> Hello,
> 
>  
> 
> My mpich2 was configured as follows
> 
>  
> 
> [eng923 at cops-021026 job]$ mpich2version
> 
> MPICH2 Version:         1.2.1p1
> 
> MPICH2 Release date:    Unknown, built on Mon Mar 29 14:37:13 BST 2010
> 
> MPICH2 Device:          ch3:nemesis
> 
> MPICH2 configure:       --prefix=/opt/mpich2
> 
> MPICH2 CC:      gcc  -O2
> 
> MPICH2 CXX:     c++  -O2
> 
> MPICH2 F77:     gfortran  -O2
> 
> MPICH2 F90:     f95  -O2
> 
>  
> 
> When I read the following (see below) in migrating from mpich1 to 
> mpich2, is this possibly causding the problem in mpi_scatter? As I am 
> using an Intel fortran compiler on a 64 bit linux platform? Would I need 
> to reinstall and configure MPIch2 and where and how do I include the 
> F90FLAGS "-i4" statement on a bash Shell?
> 
>  
> 
> D.4 Q: When I use the g95 Fortran compiler on a 64-bit
> 
> platform, some of the tests fail
> 
> A: The g95 compiler incorrectly defines the default Fortran integer as a 64-
> 
> bit integer while defining Fortran reals as 32-bit values (the Fortran 
> standard
> 
> requires that INTEGER and REAL be the same size). This was apparently
> 
> done to allow a Fortran INTEGER to hold the value of a pointer, rather
> 
> than requiring the programmer to select an INTEGER of a suitable KIND.
> 
> To force the g95 compiler to correctly implement the Fortran standard, use
> 
> the -i4 flag. For example, set the environment variable F90FLAGS before
> 
> configuring MPICH2:
> 
> setenv F90FLAGS "-i4"
> 
> G95 users should note that there (at this writing) are two distributions of
> 
> g95 for 64-bit Linux platforms. One uses 32-bit integers and reals (and
> 
> conforms to the Fortran standard) and one uses 32-bit integers and 64-bit
> 
> reals. We recommend using the one that conforms to the standard (note
> 
> that the standard specifies the /ratio /of sizes, not the absolute 
> sizes, so a
> 
> Fortran 95 compiler that used 64 bits for /both /INTEGER and REAL would
> 
> also conform to the Fortran standard. However, such a compiler would need
> 
> to use 128 bits for DOUBLE PRECISION quantities).
> 
>  
> 
> Thanks kate
> 
>  
> 
> 
> 
> The University of Aberdeen is a charity registered in Scotland, No SC013683.
> 
> 
> ------------------------------------------------------------------------
> 
> _______________________________________________
> mpich-discuss mailing list
> mpich-discuss at mcs.anl.gov
> https://lists.mcs.anl.gov/mailman/listinfo/mpich-discuss

-- 
Pavan Balaji
http://www.mcs.anl.gov/~balaji


More information about the mpich-discuss mailing list