A subgroup is some slice of a process array, formed by restricting the process coordinates in one or more dimensions to single values. A subgroup is a Group.
Any subgroup has a parent process grid and a dimension set which is some subset of the dimensions of the parent grid. The restriction operation on a group takes a slice in a particular dimension. This restriction procedure is conveniently expressed in terms of a location reference.
Suppose i is a location in a range distributed over a dimension of group p. The expression
p / i
represents a smaller group--the slice of p to which location i is mapped. (By the nature of the definition of the / operator we can see that p / i / j is equivalent to p / j / i.)
Similarly, a subrange is a section of a range, parameterized by a global index triplet. A subrange is a Range. Logically, it represents a subset of the locations of the original range.
The syntax for a subrange expression is
x | 1 : 49
x | 1 : 98 : 2
for a strided subrange.
In the above examples, both ``/'' and ``|'' are overloaded operators in HPJava.
The symbol ``:'' is a special separator. It is used to compose a triplet expression, with three optional int expression to represent an integer subset by pointing out the initial position, final position and an optional stride size. Expression :98:2, 1:98 and 1::2 are all legal triplet. The default initial and finial value are zero and the maximum value of the array index respectively. The default stride size is 1. Unlike other expressions in Java, there is no type information associate with them.