[mpich-discuss] mpifort wrapper compiler?

Jeff Squyres (jsquyres) jsquyres at cisco.com
Thu Dec 5 08:23:33 CST 2013


On Dec 4, 2013, at 7:10 PM, Pavan Balaji <balaji at mcs.anl.gov> wrote:

>> Per our prior discussions, do have an estimated timeline for when MPICH will provide an "mpifort" wrapper compiler?
> 
> Hmm.  Sorry, I totally dropped the ball on that.  I guess it’s simple enough that we could do it for the 3.1 release, but I’m not sure.  Are you guys in the process of making that the preferred compiler wrapper for Open MPI?

It already is in OMPI's 1.7 series.  Here's what's in OMPI's README:

  ********************************************************************
  ********************************************************************
  *** There is now only a single Fortran MPI wrapper compiler and 
  *** a single Fortran OSHMEM wrapper compiler:
  *** mpifort, and oshfort.  mpif77 and mpif90 still exist, but they 
  *** are symbolic links to mpifort.
  ********************************************************************
  *** Similarly, Open MPI's configure script only recognizes the FC
  *** and FCFLAGS environment variables (to specify the Fortran
  *** compiler and compiler flags, respectively).  The F77 and FFLAGS
  *** environment variables are IGNORED.
  ********************************************************************
  ********************************************************************

We also added a few warning messages in configure if someone sets the $F77 or $FFLAGS env variables.

By doing a default build of MPICH, looks like converging your mpiff7/mpif90 might be easy: it looks like the only difference between your mpif77 and mpif90 is that you pass an extra -I for where the mpi.module lives.  You can safely pass that when compiling mpif.h-based programs, too, with the added bonus that Fortran apps can use mpif.h, mpi, and mpi_f08 all in the same .f90 source file, and it'll "just work".

Hence, one possibility is to just rename your mpif90 to mpifort, and make mpif77 and mpif90 be sym links to it (and for extra bonus points, warn if someone sets $F77 / $FFLAGS in configure).

-- 
Jeff Squyres
jsquyres at cisco.com
For corporate legal information go to: http://www.cisco.com/web/about/doing_business/legal/cri/




More information about the discuss mailing list