collective, semantics of The MPI specification purposefully does not mandate whether or not collective communication operations have the side effect of synchronizing the processes over which they operate. Thus, in one valid implementation collective communication operations may synchronize processes, while in another equally valid implementation they do not. Portable MPI programs, therefore, must not rely on whether or not collective communication operations synchronize processes. Thus, the following assumptions must be avoided.
MPI_Irecv (buf2, count, MPI_INT, anticlock, tag, comm, &status); MPI_Bcast (buf3, 1, MPI_CHAR, 0, comm); MPI_Rsend (buf1, count, MPI_INT, clock, tag, comm);
Here if we want to perform the send in ready mode we must be certain that the receive has already been initiated at the destination. The above code is nonportable because if the broadcast does not act as a barrier synchronization we cannot be sure this is the case.