On Feb 13, 2014, at 10:59 PM, Saliya Ekanayake <esal...@gmail.com> wrote:
> Anyway, to answer your question I was trying to do sendrecv in a chain where > "toSend" and "receiveFrom" ranks are not the same. I was using a single > buffer, which resulted in cases where the buffer content got replaced with > received values before being able to send its original content. I think it > was an error on my side to use a single buffer in a pipeline sendrecev. I > fixed it by having two buffers. That is correct: MPI_SENDRECV does not guarantee any ordering. > I guess still with MPI_IN_PLACE this could happen. Please correct me here if > I am wrong. That is also correct. You could, however, use MPI_SENDRECV_REPLACE. It's not much more efficient than providing your own two buffers (i.e., OMPI will alloc a temporary receive buffer, and when the send is done, it'll copy from the temp to the send buffer). -- Jeff Squyres jsquy...@cisco.com For corporate legal information go to: http://www.cisco.com/web/about/doing_business/legal/cri/