![]() |
The HPJava Project |
||
|
|||
![]()
![]() ![]() ![]() |
RangesA range is a map from the integer interval 0,...,N-1 into some process dimension (ie, some dimension of a process grid). Ranges are used to parametrize distributed arrays and the overall distributed loop.In HPJava ranges are represented by objects of class Range. The most common way to create one is to use the constructor for one of the subclasses representing a ranges with specific distribution formats. A class hierarchy of ranges is given below:
The simple block distribution format implemented by BlockRange
was used directly in the matrix multiplication example.
The standard constructor for BlockRange has interface
CyclicRange is a distribution format from High Performance Fortran. The interval is mapped to the process dimension in wraparound mode, as in this example involving three processes:
The standard constructor for CyclicRange has interface
BlockCyclicRange is another distribution format from HPF. The interval is divided into blocks of some specified size which are then mapped to the process dimension in wraparound fashion. For example, with block size 2:
The standard constructor for CyclicRange has interface
A DimRange represents the range of coordinates of a process dimension, as in:
Instances of the DimRange class are usually
obtained from a Procs object through the inquiry dim:
Some of the range classes have extra constructors providing special options. For example there is a BlockRange constructor that takes extra arguments defining widths of ``ghost extensions'' for arrays created using the range. Next: Distributed arrays |