HPANDF is an extension of OSF's ANDF required to provide language-independent front-end / back-end factorization for data parallel languages such as HPF, APC++ or HPADA. This project develops HPANDF design and a prototype implementation. At the current stage, ANDF extensions required to support array operations such as Fortran90 matrix arithmetic are implemented and we are designing the translation of ALIGN and DISTRIBUTE directives.
In the ANDF framework, various languages front-ends, here referred to as ANDF "producers", translate the source codes into ANDF, and the common back-end, referred to as ANDF "installer" executes the ANDF code. First available modules within the ANDF model are: C producer by DRA and GNU CC based installer called GANDF.
The ANDF approach sounds attractive also for parallel languages and the aim of this project was to address the issue of suitable extension of ANDF, here referred to as HPANDF. A natural initial focal point is the HPF language model. However, one should in fact address first the issue of ANDF support for Fortran90. Array support in ANDF is currently limited to scalar operations such as assigning array pointers to variables and computing offsets There are no provisions for array-wide operations, such as adding whole arrays or working on array sections. These would have to be explicitly expressed in the form of looping constructs over scalar operations. However, this violates the spirit of ANDF, which is supposed to be an architecture (as well as language) independent representation of a program. Different architectures would implement array-wide operations in different ways. For example, a SIMD machine could implement such operations in a highly parallel manner, whereas a normal one-processor workstation would need to use loops over all elements.
In order to be able to express array-wide operations at a sufficiently high level within ANDF, it was necessary to extend ANDF with some tokens that represent the desired operations. These include arithmetic tokens such as: ARRAY_ADD, ARRAY_SUB, ARRAY_MUL, ARRAY_DIV, that operate on two whole integer arrays; ARRAY_NEG which operates on one integer array; and ARRAY_floating_ADD, etc. which operate on arrays of real. In addition, the token ARRAY_float_int will do the same thing as the ANDF construct float_int (i.e. promote an integer into a floating-point) but applied to a whole array.
Array sections, as used in Fortran 90, can be represented using the token SECTION which has arguments that describe the ranges of index values within each dimension that this array section should have.
By using tokens to represent these operations at a high level, it is possible for ANDF installers to implement the operations in whatever way makes the most sense for the architecture in question.
At the current stage of the project, all ANDF extensions required for translating Fortran90 are designed and implemented within a a prototype Fortran90-->ANDF producer. We are currently starting the design of HPANDF constructs corresponding to HPF directives such as ALIGN or DISTRIBUTE.
HPANDF project is related to the HPFI (High Performance Fortran Interpreter) project, also described in this portfolio. One can view the HPANDF based HPF producer as one of the candidates for the HPFI front-end layer. ANDF can be naturally trsanslated into MovieScript by converting it to the postfix syntax and providing suitable MovieScript dictionaries to handle ANDF tokens.
ANDF is an emerging standard for compiler intermediate form and a candidate for language and machine independent code distribution platform, supposedly to be accepted by all vendors. HPF, HPC++ and HPADA are candidates for standard parallel languages protocols. Development a portable distribution platform such as HPANDF would greatly facilitate multi-language or multi-architecture development projects in the HPCC domain.