next up previous

8 Message Passing Library (MPL)     continued...

Sends and receives can be blocking or non-blocking. Those that are blocking wait until the send or receive has finished before continuing with other instructions. The non-blocking ones continue with other instructions even when the send or receive has not yet finished. (Blocking operations may also be refered to as synchronous. Non-blocking operations are also called asynchronous.)

The non-blocking send and receives in FORTRAN are mp_send and mp_recv.

NOTE: All commands for C have a c between the mp and _ of the MPL commands for FORTRAN. Other MPL commands (in FORTRAN) which you may find useful are:

mp_environment returns the total number of tasks and the task's own id number.

For example, in Fortran, use

CALL mp_environ(totaltasks, task_id)

In C, use

returncharacter = mpc_environ(&totaltasks, &task_id)

mp_probe checks whether a message has arrived yet.
mp_status provides a non-blocking check of the status of a specified non-blocking send or receive, and
mp_wait which blocks to ``wait" for a non-blocking send or receive to finish.

Many other MPL operations are available. You may find more information on those, as well as the appropriate syntax for the above-listed commmands in IBM's ``AIX Parallel Environment - Parallel Programming Subroutine Reference", or try the InfoExplorer (discussed in the Additional Information section of this document).