Functions for Message Passing:
MPI processes don't share memory space and one process can't directly access other process's variables. Therefore they need some form of communication among themselves. In MPI environment this communication is in form of message passing. A message in MPI comprises the subsequent fields:
msgaddr: It can be any address in sender's address space and denotes to location in memory where message data begins.
count: Number of amount of data items of message datatype comprised in message.
Source or dest: Rank of transmitting or receiving process in communicator.
Tag: Identifier for specific message or type of message. It permits the programmer to deal with the arrival of message in a systematic way even if the arrival of the message isn't orderly.
Comm.: Communicator. It is an object wrapping context in addition group of a process. It is allocated by system rather than user.