PETSc-FUN3D Code

Satish Balay balay at mcs.anl.gov
Mon Oct 22 14:27:06 CDT 2007



On Mon, 22 Oct 2007, Lisandro Dalcin wrote:

> Sathis, I have not much experience with fortran, but... if you take a
> look for example at
> 
> http://www.mpi-forum.org/docs/mpi-20-html/node54.htm
> 
> you will see
> 
> MPI_ALLOC_MEM(SIZE, INFO, BASEPTR, IERROR)
> INTEGER INFO, IERROR
> INTEGER(KIND=MPI_ADDRESS_KIND) SIZE, BASEPTR
> 
> So what the meaning of INTEGER(KIND=MPI_ADDRESS_KIND) is supposed to be??

If you check mpich2-1.0.5p4/src/binding/f77/type_extentf.c

#include "fproto.h"
FORT_DLL_SPEC void FORT_CALL mpi_type_extent_ ( MPI_Fint *v1, MPI_Fint * v2, MPI_Fint *ierr ){
    MPI_Aint l2;
    *ierr = MPI_Type_extent( (MPI_Datatype)(*v1), &l2 );
    *v2 = (MPI_Fint)(l2);
}

MPI_Aint [on the c side] is used ambiguously as either
INTEGER(KIND=MPI_ADDRESS_KIND) for MPI_ALLOC_MEM or 'INTEGER' for
MPI_Type_extent.


Satish




More information about the petsc-dev mailing list