Newsgroups: comp.parallel.mpi
From: Anders Liverud <al@inko.no>
Subject: Ordering of MPI messages in multi-threaded programs
Organization: Kongsberg Informasjonskontroll
Date: Tue, 20 Aug 1996 09:16:05 +0200
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Message-ID: <32196635.3C6B@inko.no>

Given a multithreaded application, having two threads per process, where 
each thread pair uses its distinct tag, the following situation might 
occur:

Rank 0 - Thread 0 : MPI_Send( ..., tag0, ...)
Rank 0 - Thread 1 : MPI_Send( ..., tag1, ...)
Rank 1 - Thread 0 : MPI_Recv( ..., tag1, ...)
Rank 1 - Thread 1 : MPI_Recv( ..., tag0, ...)

Clause 3.5, pg. 31, MPI Std. 12 June 1995, states that these calls are 
unordered. Is this program "unsafe"?

________________________________________ 
Anders Liverud (al)
Kongsberg Informasjonskontroll AS (nord)
Hvamstubben 17, 2013 SKJETTEN, NORWAY
tlf : +47 6384 5600
Fax : +47 6384 5922
e-mail : al@inko.no

