Boost logo

Boost Users :

Subject: Re: [Boost-users] [mpi] potentially blocking send - require blocking
From: Ilja Honkonen (ilja.honkonen_at_[hidden])
Date: 2014-07-23 20:39:01


Hello
> The boost::mpi documentation for send() is:
> "This routine executes a potentially blocking send"
> This differs from MPI_Send()
> "This routine will block until the message is sent to the destination."

Both are correct in practice, whether MPI_Send actually blocks is
implementation (and message, etc.) dependent.

> I am developing an application which requires the code not to progress
> until the communication is complete.

I think you'll need an MPI_Barrier after send/recv for that.

> In which situations does "potentially blocking" apply?
> And, is there a way of guaranteeing it is complete, the equivalent of
> MPI_Wait() for MPI_Isend()?

At least in MPI-1.1 none of the send functions (including MPI_Wait on
MPI_Isend) guarantee that the message has been received when send
returns, they only guarantee that the buffer where the message was read
from by send can be reused.

http://www.mpi-forum.org/docs/mpi-1.1/mpi-11-html/node40.html
http://www.mpi-forum.org/docs/mpi-1.1/mpi-11-html/node47.html

Ilja


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net