The rules on subscripts given in the last two subsections go a long
way towards ensuring a crucial requirement of HPJava, namely that
a process may only access locally held array elements.
There are still odd
cases--typically involving array sections--where those rules are insufficient.
Consider the pathological example of Figure 5.1.
The subscripts on the element reference b [j] are legal--j
is certainly a location in b.rng(0) (which is equal to y).
But, as illustrated, the section
b is localized to
--the top row
of processes in the figure--whereas the at construct
specifies that the element assignments are performed in the group
--the bottom row of processes.
![]() |
This kind of error can be excluded by the following rule:
The error above is now exposed, because the distribution group of b
is
. This does not
contain the active process group inside the overall construct, namely
. So
the processes executing the array access fail to meet the criterion
of rule 8.