|
Rance Necaise
Visiting Associate Professor of Computer Science |
||
|
|
||
|
Message Passing« Preliminaries | Table of Contents | Message Passing Non-blocking »
int MPI_Bcast( void *buf, int count, MPI_Datatype datatype,
int MPI_Send( void *buf, int count, MPI_Datatype datatype,
int MPI_Recv( void *buf, int count, MPI_Datatype datatype,
int MPI_Reduce( void *sendbuf, void *recvbuf, int count, int MPI_Probe( int srcPid, int tag, MPI_Comm comm, MPI_Status *status ); Blocks and waits for a message with the given data
int MPI_Get_count( MPI_Status *status, MPI_Datatype datatype, int *count ) Determines the number of data items contained in a message just received or the next message to be received. This function is used with either MPI_Recv() or MPI_Probe().
The following code segment illustrates the use of this function MPI_Status msgStatus; int numItems; MPI_Probe( ROOT_PROC, DATA_TAG, MPI_COMM_WORLD, &msgStatus ); MPI_Get_count( &msgStatus, MPI_DOUBLE, &numItems );
|