Open MPI logo

Open MPI User's Mailing List Archives

  |   Home   |   Support   |   FAQ   |   all Open MPI User's mailing list

Subject: Re: [OMPI users] Sending relatively large messages with highfrequency
From: Jeff Squyres (jsquyres_at_[hidden])
Date: 2010-02-25 09:40:06

On Feb 25, 2010, at 3:56 AM, Amr Hassan wrote:

> Thanks alot for your reply,
> I'm using blocking Send and Receive. All the clients are sending data and the server is receive the messages from the clients with MPI_ANY_SOURCE as the sender. Do you think there is a race condition near this pattern?

MPI_ANY_SOURCE can definitely lead to race conditions / messages (and content) from unexpected sources. Try using explicit sources, if possible.

> I searched a lot and used totalview but I couldn't detect such case. I really appreciate if you send me a link or give an example of a possible race condition in that scenario .

You might want to let it run to segv in TV and see exactly where the segv occurs in your code. Is your code processing what it thinks is message A but is really message B? If the content (and therefore the processing of) B is different than A, then assumptions can go badly in your code and Bad Things may happen.

> Also, when I partition the message into smaller parts (send in sequence - all the other clients wait until the send finish) it works fine. is that exclude the race condition?

No. It somewhat suggests that you do have a race condition.

Jeff Squyres
For corporate legal information go to: