blob: 4035e56ee8ca0f075034a59e2081ceb0e5037b04 [file] [log] [blame]
.\"Copyright 2008-2010 IBM Corp.
.TH SCI_Group_operate_ext 3 "Dec 4, 2009" "1.0.0" "SCI"
.SH NAME
\fBSCI_Group_operate_ext\fP \- Create a new group from an existed group and a back end list
.SH SYNTAX
.ft R
.SH C Syntax
.nf
#include <sci.h>
int SCI_Group_operate(sci_group_t \fIgroup\fP, int \fInum_bes\fP, int *\fIbe_list\fP, sci_op_t \fIop\fP, sci_group_t *\fInewgroup\fP)
.SH INPUT PARAMETERS
.ft R
.TP 1i
group
An existed group (IN).
.TP 1i
num_bes
Number of back ends in another group (IN).
.TP 1i
be_list
The back end id list of another group (IN).
.TP 1i
op
Indicates how to create the new group (IN).
.TP 1i
newgroup
The output new group (OUT).
.SH DESCRIPTION
.ft R
This subroutine is used to create a new group from an existed group and a back end list,
\fIgroup\fP can be \fBSCI_GROUP_ALL\fP, and \fIop\fP can be \fBSCI_UNION\fP,
\fBSCI_INTERSECTION\fP and \fBSCI_DIFFERENCE\fP. The new \fInewgroup\fP can be
used for \fBSCI_Bcast\fP to specify destination receivers.
.sp
This is a blocking call. The caller can assume \fInewgroup\fP is ready to use upon the return
of the function.
.sp
For more information, please refer to SCI's online documents.
.SH EXAMPLE
.ft R
.nf
{
int i, num_bes, *be_list;
sci_group_t group, newgroup;
...
num_bes = 3;
be_list = (int *)malloc(sizeof(int)*num_bes);
for (i=0; i<num_bes; i++) {
be_list[i] = i;
}
SCI_Group_operate_ext(group, num_bes, be_list, SCI_UNION, &newgroup);
}
.fi
.SH ERRORS
.ft R
All SCI routines return an error value.
.sp
.TP 1i
SCI_ERR_UNINTIALIZED
Uninitialized SCI execution environment
.TP 1i
SCI_ERR_INVALID_CALLER
Can only be called in the front end
.TP 1i
SCI_ERR_GROUP_NOTFOUND
The group to be freed does not exist
.TP 1i
SCI_ERR_BACKEND_NOTFOUND
The back end id list contains non-existed back end id
.TP 1i
SCI_ERR_INVALID_OPERATOR
Incorrect \fIop\fP specified
.TP 1i
SCI_ERR_GROUP_EMPTY
The new group is an empty group
.TP 1i
SCI_ERR_NO_MEM
Out of memory
.SH SEE ALSO
.ft R
.nf
\fBSCI_Group_create\fP(3)
\fBSCI_Group_free\fP(3)
\fBSCI_Group_operate\fP(3)