Open MPI logo

Open MPI User's Mailing List Archives

  |   Home   |   Support   |   FAQ   |   all Open MPI User's mailing list

Subject: Re: [OMPI users] MPI_TYPE_CREATE_SUBARRAY not in mpif90 library
From: Jeff Squyres (jsquyres_at_[hidden])
Date: 2011-02-16 16:39:55


Were you able to check that their code matches the type signature that Open MPI is exporting? Specifically, double check that the types of the parameters that the code is passing as arguments to MPI_TYPE_CREATE_SUBARRAY match the types in the signature that I sent in my original reply. I verified that OMPI v1.4.x's signature matches what is listed in MPI-2.2 p87.

Absent any other information, I am guessing that his code is incorrect.

I'm hazarding a guess here: it's possible that this code works with other MPI's because they don't offer an F90 binding for MPI_TYPE_CREATE_SUBARRAY. I.e., your user can call this function from an F90 MPI code, but it just "falls through" (with no compiler checking) to that MPI's underlying F77 function.

Open MPI actually implements the F90 compiler checking before letting the implementation "fall through" to the underlying F77 function -- many other MPI's do not. ...or at least, many other MPI implementations *did* not; but I admit that I haven't checked in a while. Note, too, that it's perfectly allowable for MPI implementations to *not* do the compiler checking because the F90 bindings are classified as "optional" in the MPI specification.

Finally, I note that we've had a few F90 bindings fixes in between 1.4.x and 1.5.x, but only in the following functions:

MPI_COMM_CREATE_KEYVAL
MPI_GREQUEST_START
MPI_OP_CREATE
MPI_REGISTER_DATAREP
MPI_TYPE_CREATE_KEYVAL
MPI_WIN_CREATE_KEYVAL

I'm actually a little surprised that we (I) forgot to back-port these fixes to the 1.4.x series; I'll do so now...

On Feb 16, 2011, at 1:16 PM, Petit, George (Cont, ARL/CISD) wrote:

> Jeff,
>
> The problem occurs in both OpenMPI 1.3 and 1.4. The user is also reporting that he's experiencing this problem on other systems as well.
>
> George Petit
> Lockheed Martin
> ARL DSRC Customer Support Team Lead
> george.petit_at_[hidden]
> 410-278-9283
>
>
> From: users-bounces_at_[hidden] on behalf of Jeff Squyres
> Sent: Wed 2/16/2011 10:40 AM
> To: Open MPI Users
> Subject: Re: [OMPI users] MPI_TYPE_CREATE_SUBARRAY not in mpif90 library
>
> What version of Open MPI are you using?
>
> I just checked a trivial f90 MPI program and MPI_TYPE_CREATE_SUBARRAY seemed to work ok.
>
> I am not a fortran expert, but when I have seen this type of error message before, it *usually* meant that there was a type mismatch between the types passed to the function and the function signature available in the f90 module. I.e., the compiler found a function matching the *name*, but wasn't able to find a match for the *type signature*.
>
> Here's Open MPI's declaration of MPI_TYPE_CREATE_SUBARRAY:
>
> -----
> interface MPI_Type_create_subarray
> subroutine MPI_Type_create_subarray(ndims, size_array, subsize_array, start_array, order, &
> oldtype, newtype, ierr)
> integer, intent(in) :: ndims
> integer, dimension(*), intent(in) :: size_array
> integer, dimension(*), intent(in) :: subsize_array
> integer, dimension(*), intent(in) :: start_array
> integer, intent(in) :: order
> integer, intent(in) :: oldtype
> integer, intent(out) :: newtype
> integer, intent(out) :: ierr
> end subroutine MPI_Type_create_subarray
> end interface
> -----
>
> One thing you might want to double check is that OMPI was compiled with MPI_REAL8 support (since MPI_REAL8 was passed to the subroutine). Run this:
>
> -----
> shell$ ompi_info --all | grep real8
> Fort have real8: yes
> Fort real8 size: 8
> Fort real8 align: 8
> shell$
> -----
>
> Finally, note that Open MPI doesn't have many of the F90 symbols that you might expect in libmpi_f90.so because most of our F90 support is "direct pass through" to the F77 subroutines. Specifically, our F90 mpi module simply provides compile-time checking for expected signatures, but the subroutine call is actually automatically linked against the corresponding symbol in libmpi_f77.so. Only a few subroutines -- i.e., the ones that have multiple different type signatures -- actually appear in libmpi_f90.so.
>
> Meaning: MPI_TYPE_CREATE_SUBARRAY only has one type signature. So it's normal / expected that you don't see /mpi_type_subarray/i in libmpi_f90.so.
>
>
> On Feb 15, 2011, at 1:18 PM, Petit, George (Cont, ARL/CISD) wrote:
>
> > A user posted the following ticket to our site. Should the referenced MPI routine be included in the mpif90 library? If not, why? And is there a way to get it added.
> >
> > -----------------------------------------------------------------------------------------------------------------------------------------------------------------------------
> > I receive the following error when I try to compile my code with ifort with the
> > openmpi library:
> >
> > grid.f(38): error #6285: There is no matching specific subroutine for this generic
> > subroutine call. [MPI_TYPE_CREATE_SUBARRAY]
> > call
> > mpi_type_create_subarray(3,isizes,isubs,istarts,MPI_ORDER_FORTRAN,MPI_REAL8,DTghost(1),ierr)
> > -------------^
> >
> > It looks like the 'mpi_type_create_subarray' routine is missing from the openmpi
> > library libmpi_f90.so. The routine is in libmpi_f77.so. Is it possible to add it
> > to the f90 library? The fortran 90 versions of mpi for sgi_mpt, xt-mpt, ibm-mpi and
> > intelmpi all include this routine. Thanks. -Rob
> >
> > George Petit
> > Lockheed Martin
> > ARL DSRC Customer Support Team Lead
> > george.petit_at_[hidden]
> > 410-278-9283
> >
> >
> > _______________________________________________
> > users mailing list
> > users_at_[hidden]
> > http://www.open-mpi.org/mailman/listinfo.cgi/users
>
>
> --
> Jeff Squyres
> jsquyres_at_[hidden]
> For corporate legal information go to:
> http://www.cisco.com/web/about/doing_business/legal/cri/
>
>
> _______________________________________________
> users mailing list
> users_at_[hidden]
> http://www.open-mpi.org/mailman/listinfo.cgi/users
>
> _______________________________________________
> users mailing list
> users_at_[hidden]
> http://www.open-mpi.org/mailman/listinfo.cgi/users

-- 
Jeff Squyres
jsquyres_at_[hidden]
For corporate legal information go to:
http://www.cisco.com/web/about/doing_business/legal/cri/