Research Article

Optimized Data Transfers Based on the OpenCL Event Management Mechanism

Algorithm 3

cl_int
clEnqueueRecvBuffer(cl_command_queue cmd, /* command queue */
cl_mem buf, /* memory buffer to receive data */
cl_bool blocking, /* blocking function call */
size_t offset,    /* offset */
size_t size,        /* buffer size */
int src,               /* senders rank */
int tag,          /* tag */
MPI_Comm comm,  /* communicator */
cl_uint numevts, /* the number of events in the list */
const cl_event* wlist, /* event list */
cl_event* evtret ) /* event object of the function call */