YAP 7.1.0
MPI Interface

This library provides a set of utilities for interfacing with LAM MPI. More...

Detailed Description

This library provides a set of utilities for interfacing with LAM MPI.

The following routines are available once included with the use_module(library(lam_mpi)) command The yap should be invoked using the LAM mpiexec or mpirun commands (see LAM manual for more details)


Class Documentation

◆ mpi_bcast2/2

class mpi_bcast2/2

mpi_bcast2(+ Root, ? Data)

Broadcasts the message Data from the process with rank Root to all other processes

◆ mpi_comm_rank/1

class mpi_comm_rank/1

mpi_comm_rank(- Rank)

Unifies Rank with the rank of the current process in the MPI environment

◆ mpi_comm_size/1

class mpi_comm_size/1

mpi_comm_size(- Size)

Unifies Size with the number of processes in the MPI environment

◆ mpi_irecv/3

class mpi_irecv/3

mpi_irecv(? Source,? Tag,- Handle)

Non-blocking communication predicate The predicate returns an Handle for a message that will be received from processor with rank Source and tag Tag Note that the predicate succeeds immediately, even if no message has been received The predicate mpi_wait_recv should be used to obtain the data associated to the handle

◆ mpi_isend/4

class mpi_isend/4

mpi_isend(+ Data,+ Dest,+ Tag,- Handle)

Non blocking communication predicate The message in Data, with tag Tag, is sent whenever possible to the processor with rank Dest An Handle to the message is returned to be used to check for the status of the message, using the mpi_wait or mpi_test predicates Until mpi_wait is called, the memory allocated for the buffer containing the message is not released

◆ mpi_msg_size/2

class mpi_msg_size/2

mpi_msg_size( Msg, - MsgSize)

Unify MsgSize with the number of bytes YAP would need to send the message Msg

◆ mpi_recv/3

class mpi_recv/3

mpi_recv(? Source,? Tag,- Data)

Blocking communication predicate The predicate blocks until a message is received from processor with rank Source and tag Tag The message is placed in Data

◆ mpi_send/3

class mpi_send/3

mpi_send(+ Data,+ Dest,+ Tag)

Blocking communication predicate The message in Data, with tag Tag, is sent immediately to the processor with rank Dest The predicate succeeds after the message being sent

◆ mpi_test/2

class mpi_test/2

mpi_test(? Handle,- Status)

Provides information regarding the handle Handle, ie., if a communication operation has been completed If the operation associate with Hanlde has been completed the predicate succeeds with the completion status in Status, otherwise it fails

◆ mpi_test_recv/3

class mpi_test_recv/3

mpi_test_recv(? Handle,- Status,- Data)

Provides information regarding a handle If the message associated with handle Hanlde is buffered then the predicate succeeds unifying Status with the status of the message and Data with the message itself Otherwise, the predicate fails

◆ mpi_version/2

class mpi_version/2

mpi_version(- Major,- Minor)

Unifies Major and Minor with, respectively, the major and minor version of the MPI

◆ mpi_wait/2

class mpi_wait/2

mpi_wait(? Handle,- Status)

Completes a non-blocking operation If the operation was a mpi_send, the predicate blocks until the message is buffered or sent by the runtime system At this point the send buffer is released If the operation was a mpi_recv, it waits until the message is copied to the receive buffer Status is unified with the status of the message

◆ mpi_wait_recv/3

class mpi_wait_recv/3

mpi_wait_recv(? Handle,- Status,- Data)

Completes a non-blocking receive operation The predicate blocks until a message associated with handle Hanlde is buffered The predicate succeeds unifying Status with the status of the message and Data with the message itself