This source file includes following definitions.
- ompi_iscatter_f
   1 
   2 
   3 
   4 
   5 
   6 
   7 
   8 
   9 
  10 
  11 
  12 
  13 
  14 
  15 
  16 
  17 
  18 
  19 
  20 
  21 
  22 
  23 #include "ompi_config.h"
  24 
  25 #include "ompi/mpi/fortran/mpif-h/bindings.h"
  26 #include "ompi/mpi/fortran/base/constants.h"
  27 
  28 #if OMPI_BUILD_MPI_PROFILING
  29 #if OPAL_HAVE_WEAK_SYMBOLS
  30 #pragma weak PMPI_ISCATTER = ompi_iscatter_f
  31 #pragma weak pmpi_iscatter = ompi_iscatter_f
  32 #pragma weak pmpi_iscatter_ = ompi_iscatter_f
  33 #pragma weak pmpi_iscatter__ = ompi_iscatter_f
  34 
  35 #pragma weak PMPI_Iscatter_f = ompi_iscatter_f
  36 #pragma weak PMPI_Iscatter_f08 = ompi_iscatter_f
  37 #else
  38 OMPI_GENERATE_F77_BINDINGS (PMPI_ISCATTER,
  39                             pmpi_iscatter,
  40                             pmpi_iscatter_,
  41                             pmpi_iscatter__,
  42                             pompi_iscatter_f,
  43                             (char *sendbuf, MPI_Fint *sendcount, MPI_Fint *sendtype, char *recvbuf, MPI_Fint *recvcount, MPI_Fint *recvtype, MPI_Fint *root, MPI_Fint *comm, MPI_Fint *request, MPI_Fint *ierr),
  44                             (sendbuf, sendcount, sendtype, recvbuf, recvcount, recvtype, root, comm, request, ierr) )
  45 #endif
  46 #endif
  47 
  48 #if OPAL_HAVE_WEAK_SYMBOLS
  49 #pragma weak MPI_ISCATTER = ompi_iscatter_f
  50 #pragma weak mpi_iscatter = ompi_iscatter_f
  51 #pragma weak mpi_iscatter_ = ompi_iscatter_f
  52 #pragma weak mpi_iscatter__ = ompi_iscatter_f
  53 
  54 #pragma weak MPI_Iscatter_f = ompi_iscatter_f
  55 #pragma weak MPI_Iscatter_f08 = ompi_iscatter_f
  56 #else
  57 #if ! OMPI_BUILD_MPI_PROFILING
  58 OMPI_GENERATE_F77_BINDINGS (MPI_ISCATTER,
  59                             mpi_iscatter,
  60                             mpi_iscatter_,
  61                             mpi_iscatter__,
  62                             ompi_iscatter_f,
  63                             (char *sendbuf, MPI_Fint *sendcount, MPI_Fint *sendtype, char *recvbuf, MPI_Fint *recvcount, MPI_Fint *recvtype, MPI_Fint *root, MPI_Fint *comm, MPI_Fint *request, MPI_Fint *ierr),
  64                             (sendbuf, sendcount, sendtype, recvbuf, recvcount, recvtype, root, comm, request, ierr) )
  65 #else
  66 #define ompi_iscatter_f pompi_iscatter_f
  67 #endif
  68 #endif
  69 
  70 
  71 void ompi_iscatter_f(char *sendbuf, MPI_Fint *sendcount,
  72                      MPI_Fint *sendtype, char *recvbuf,
  73                      MPI_Fint *recvcount, MPI_Fint *recvtype,
  74                      MPI_Fint *root, MPI_Fint *comm, MPI_Fint *request,
  75                      MPI_Fint *ierr)
  76 {
  77     int c_ierr;
  78     MPI_Datatype c_sendtype, c_recvtype;
  79     MPI_Request c_request;
  80     MPI_Comm c_comm = PMPI_Comm_f2c(*comm);
  81 
  82     c_sendtype = PMPI_Type_f2c(*sendtype);
  83     c_recvtype = PMPI_Type_f2c(*recvtype);
  84 
  85     sendbuf = (char *) OMPI_F2C_BOTTOM(sendbuf);
  86     recvbuf = (char *) OMPI_F2C_IN_PLACE(recvbuf);
  87     recvbuf = (char *) OMPI_F2C_BOTTOM(recvbuf);
  88 
  89     c_ierr = PMPI_Iscatter(sendbuf,OMPI_FINT_2_INT(*sendcount),
  90                           c_sendtype, recvbuf,
  91                           OMPI_FINT_2_INT(*recvcount),
  92                           c_recvtype,
  93                           OMPI_FINT_2_INT(*root), c_comm, &c_request);
  94     if (NULL != ierr) *ierr = OMPI_INT_2_FINT(c_ierr);
  95     if (MPI_SUCCESS == c_ierr) *request = PMPI_Request_c2f(c_request);
  96 }