Getting information about a message


Up: Sending and Receiving messages Next: Simple Fortran example Previous: MPI Basic Send/Receive


MPI_Status status; 
MPI_Recv( ..., &status ); 
... status.MPI_TAG; 
... status.MPI_SOURCE; 
MPI_Get_count( &status, datatype, &count ); 
MPI_TAG and MPI_SOURCE primarily of use when MPI_ANY_TAG and/or MPI_ANY_SOURCE in the receive.

MPI_Get_count may be used to determine how much data of a particular type was received.



Up: Sending and Receiving messages Next: Simple Fortran example Previous: MPI Basic Send/Receive