blob: 0a530181639df5904aca251605ee69fb643c776f [file] [log] [blame]
NAME
SCI_Upload - Uploads messages from a back end to the front end
C Syntax
#include <sci.h>
int SCI_Upload(int filter_id, sci_group_t group, int num_bufs, void *bufs[], int sizes[])
INPUT PARAMETERS
filter_id
The id of the message filter (IN).
group
The group which the message belongs to (IN).
num_bufs
The number of buffers of current message segment (IN).
bufs
The array of buffer locations of current message segment (IN).
sizes
The array of buffer sizes of current message segment (IN).
DESCRIPTION
This subroutine is used to upload message from a back end to the front end. The
message can be sent directly to the front end if set filter_id to SCI_FILTER_NULL,
or can be sent to the filter indicated by filter_id if a new message filter is loaded
by SCI_Filter_load.
This is a non-blocking call. The caller cannot assume that message transfer has
completed upon the return of the function. Instead, the handler function defined in
sci_info_t should be used to ensure the message arrival in the destination sides.
For more information, please refer to SCI's online documents.
EXAMPLE
{
char msg[256];
int sizes[1];
void *bufs[1];
...
bufs[0] = msg;
sizes[0] = strlen(msg) + 1;
SCI_Upload(SCI_FILTER_NULL, SCI_GROUP_ALL, 1, bufs, sizes);
}
ERRORS
All SCI routines return an error value.
SCI_ERR_UNINTIALIZED
Uninitialized SCI execution environment
SCI_ERR_INVALID_CALLER
Can only be called in the front end
SCI_ERR_NO_MEM
Out of memory
SEE ALSO
SCI_Bcast(3)
SCI_Poll(3)