[mvapich-discuss] Hello World, MPI-3.0 and mpi_f08

Thompson, Matt (GSFC-610.1)[SCIENCE SYSTEMS AND APPLICATIONS INC] matthew.thompson at nasa.gov
Tue Dec 17 09:12:10 EST 2013


MVAPICH2 List,

In trying to get used to all the new features of MPI-3.0 and Fortran 
support, I recently whipped up a simple program following the Green 
Book. Obviously since all compilers might not support all the bits of 
Fortran 2008 needed for full compliance, I chose a simple example, Hello 
World, to start out:

****

program hello_world

    use mpi_f08

    implicit none

    type(MPI_Comm) :: comm
    integer :: myid, npes, ierror
    integer :: name_length

    character(len=MPI_MAX_PROCESSOR_NAME) :: processor_name

    call mpi_init(ierror)

    comm = MPI_COMM_WORLD

    call MPI_Comm_rank(comm,myid,ierror)
    call MPI_Comm_size(comm,npes,ierror)
    call MPI_Get_processor_name(processor_name,name_length,ierror)

    write (*,'(A,X,I4,X,A,X,I4,X,A,X,A)') "Process", myid, "of", npes, 
"is on", trim(processor_name)

    call MPI_Finalize(ierror)

end program hello_world

****

As far as I can tell, this is MPI-3.0 standards compliant, and Open MPI 
1.7.3 (which, as far as I know, doesn't support as much of MPI-3.0 as 
MVAPICH2 does) runs it just fine.

However, when I try to compile it with MVAPICH2 2.0b, it bombs out 
because it can't find the mpi_f08 module. And, fair enough, I can't seem 
to see it anywhere in the MVAPICH2 installation directory (include/, I'm 
guessing since mpi.mod is there).

So, I guess my question is does MVAPICH2 support mpi_f08? Or is that 
more a question of does MPICH support mpi_f08...and if they don't, 
MVAPICH2 can't?

Thanks,
Matt

-- 
Matt Thompson, PhD     SSAI, Sr Software Test Engr
NASA GSFC, Global Modeling and Assimilation Office
Code 610.1, 8800 Greenbelt Rd, Greenbelt, MD 20771
Phone: 301-614-6712              Fax: 301-614-6246



More information about the mvapich-discuss mailing list