|
The basic point-to-point communication operations are send and receive.
MOC_Send uses either buffered or synchronous send depending on the message-size (Short messages are transmitted using buffered send and long messages are transmitted using synchronous send).
MOC_Recv receives all messages irrespective wether buffered or synchronous communication is used.
Modules | |
| Return Status | |
| Receiving operations return a status-object holding information about the message. | |
| Datatypes | |
| Datatypes supported by MOC. | |
| Synchronous Communication | |
| Direct blocking sending of messages without any intermediate buffer. | |
| Buffered Communication | |
| Blocking sending of messages with the use of an intermediate buffer. | |
| Send-Receive | |
| The send-receive operations combine in one call the sending of a message to one destination and the receiving of another message, from another process. | |
| Non-Blocking Communication | |
| Non-blocking sending and receiving messages. | |
Defines | |
| #define | MOC_SEND_TRESHOLD 4096 |
| Indicates, at which message-size MOC_Send switches to synchronous send. | |
Functions | |
| int | MOC_Send (void *buf, int count, MOC_Datatype datatype, int dest, int tag, MOC_Comm comm) |
| Performs a blocking standard mode send operation. | |
| int | MOC_Recv (void *buf, int count, MOC_Datatype datatype, int source, int tag, MOC_Comm comm, MOC_Status *status) |
| Performs a blocking standard mode receive operation. | |
| int | MOC_Probe (int source, int tag, MOC_Comm comm, MOC_Status *status) |
| Waits till a message is received and returns information without actually receiving the message. | |
| int | MOC_Iprobe (int source, int tag, MOC_Comm comm, int *flag, MOC_Status *status) |
| Tests if a message is available and returns information without actually receiving the message. | |
| int MOC_Iprobe | ( | int | source, | |
| int | tag, | |||
| MOC_Comm | comm, | |||
| int * | flag, | |||
| MOC_Status * | status | |||
| ) |
Tests if a message is available and returns information without actually receiving the message.
| source | in source of message | |
| tag | in message-tag | |
| comm | in communicator | |
| flag | out boolean value telling if a message is available | |
| status | out status-object holding information about message |
| MOC_SUCCESS | No error; MPI routine completed successfully. | |
| ... | error-code |
| int MOC_Probe | ( | int | source, | |
| int | tag, | |||
| MOC_Comm | comm, | |||
| MOC_Status * | status | |||
| ) |
Waits till a message is received and returns information without actually receiving the message.
| source | in source of message | |
| tag | in message-tag | |
| comm | in communicator | |
| status | out status-object holding information about message |
| MOC_SUCCESS | No error; MPI routine completed successfully. | |
| ... | error-code |
| int MOC_Recv | ( | void * | buf, | |
| int | count, | |||
| MOC_Datatype | datatype, | |||
| int | source, | |||
| int | tag, | |||
| MOC_Comm | comm, | |||
| MOC_Status * | status | |||
| ) |
Performs a blocking standard mode receive operation.
| buf | inout Buffer into which data should be stored | |
| count | in Number of elements in receive buffer (not equal to actual byte-value) | |
| datatype | in Datatype of each receive buffer element | |
| source | in Rank of source | |
| tag | in Tag of message | |
| comm | in Communicator of message | |
| status | inout Object holding status-information (has to be allocated by user) |
| MOC_SUCCESS | No error; MPI routine completed successfully. | |
| ... | error-code |
| int MOC_Send | ( | void * | buf, | |
| int | count, | |||
| MOC_Datatype | datatype, | |||
| int | dest, | |||
| int | tag, | |||
| MOC_Comm | comm | |||
| ) |
Performs a blocking standard mode send operation.
| buf | in Pointer to buffer where data is stored | |
| count | in Number of elements to be send (not equal to actual byte-value) | |
| datatype | in Type of elements to be send | |
| dest | in Rank of receiving process | |
| tag | in Tag of message | |
| comm | in communicator of message |
| MOC_SUCCESS | No error; MPI routine completed successfully. | |
| ... | error-code |
1.5.6