[mpich-discuss] Message ordering with mpich

Pavan Balaji balaji at mcs.anl.gov
Tue Mar 8 18:37:43 CST 2011


I'm not entirely sure what you are trying to do here, but MPI provides 
matching from one process to another process on the same communicator 
and same tag.

In other words, if a process P0 sends two messages to P1 on the same 
communicator + same tag, they are *matched* (not necessarily completed) 
in the same order on P1.

P0:
Isend(msg1, P1, tag, comm);
Isend(msg2, P1, tag, comm);

P1:
Irecv(msg3, P0, tag, comm);
Irecv(msg4, P0, tag, comm);

msg3 matches msg1. msg4 matches msg2.

  -- Pavan

On 03/08/2011 05:55 PM, James Edmondson wrote:
> Does synchronous MPI_Ssend/MPI_Recv really accomplish this? I would
> think that a custom solution would be required for a global ordering,
> one that actually maintains lamport clocks and breaks ties with
> process identifiers, or something similar - like a sequencer, which is
> less efficient because it requires a bottleneck akin to a token
> authority for the next entity in the global total order.
>
> Similarly, causal ordering could be supported with vectorized data
> types to keep track of the causal ordering (current receipt clocks
> from P0, P1, etc.). If you have some links to where the standard
> supports global ordering via MPI_Ssend/MPI_Recv or how this might be
> accomplished without a custom solution, would you mind sharing some
> links? Or are you saying that MPI_Ssend ensures FIFO channels between
> each entity? Because the latter doesn't imply any type of total
> ordering (e.g. if P0 sent a message before P1 sent a message, then P3
> receives and processes P0's message before P1.)
>
> Thanks,
> James Edmondson
> Vanderbilt University ISIS
>
>
> On Tue, Mar 8, 2011 at 4:35 PM, James Dinan<dinan at mcs.anl.gov>  wrote:
>> I think you should be able to achieve this with synchronous
>> MPI_Ssend/MPI_Recv.
>>
>>   ~Jim.
>>
>> On 3/8/11 8:56 AM, h banki wrote:
>>>
>>> Hi,
>>>
>>> I want to send messages in total ordering between processes, how can I
>>> do this? is there any special code?
>>>
>>>
>>>
>>> --- On *Tue, 3/8/11, Darius Buntinas /<buntinas at mcs.anl.gov>/* wrote:
>>>
>>>
>>>     From: Darius Buntinas<buntinas at mcs.anl.gov>
>>>     Subject: Re: [mpich-discuss] Message ordering with mpich
>>>     To: mpich-discuss at mcs.anl.gov
>>>     Date: Tuesday, March 8, 2011, 8:43 AM
>>>
>>>
>>>     In MPI, all messages between two processes sent on the same
>>>     communicator are FIFO ordered.
>>>
>>>     -d
>>>
>>>     On Mar 8, 2011, at 8:30 AM, h banki wrote:
>>>
>>>      >  Hello,
>>>      >
>>>      >  I want to know that is there any way to implement message
>>>     ordering (FIFO, Total, Causal) with mpich?
>>>      >  is there any document about this issue?
>>>      >
>>>      >  Regards,
>>>      >  Banki
>>>      >
>>>      >  _______________________________________________
>>>      >  mpich-discuss mailing list
>>>      >  mpich-discuss at mcs.anl.gov</mc/compose?to=mpich-discuss at mcs.anl.gov>
>>>      >  https://lists.mcs.anl.gov/mailman/listinfo/mpich-discuss
>>>
>>>     _______________________________________________
>>>     mpich-discuss mailing list
>>>     mpich-discuss at mcs.anl.gov</mc/compose?to=mpich-discuss at mcs.anl.gov>
>>>     https://lists.mcs.anl.gov/mailman/listinfo/mpich-discuss
>>>
>>>
>>>
>>>
>>> _______________________________________________
>>> mpich-discuss mailing list
>>> mpich-discuss at mcs.anl.gov
>>> https://lists.mcs.anl.gov/mailman/listinfo/mpich-discuss
>>
>> _______________________________________________
>> mpich-discuss mailing list
>> mpich-discuss at mcs.anl.gov
>> https://lists.mcs.anl.gov/mailman/listinfo/mpich-discuss
>>
> _______________________________________________
> mpich-discuss mailing list
> mpich-discuss at mcs.anl.gov
> https://lists.mcs.anl.gov/mailman/listinfo/mpich-discuss

-- 
Pavan Balaji
http://www.mcs.anl.gov/~balaji


More information about the mpich-discuss mailing list