normDDe (1158428), страница 4
Текст из файла (страница 4)
<name-variable>::=<token code>
<name-domain>::=<token code> OR ‘S’
This information means that variable with name <name-variable> on domain <name-domain> (if <name-variable> - name of scalar variable, then <name-domain>=’S’) is computed in the operator with <statement number>.
For instance, this table allows checking the character of single-assignment for the variables of Norma part unit with great effect.
3.13Table of operators body
Table of operators body is used for holding the bodies of operators in the form applied to generation of target Fortran program. The variables included into the operators have index expressions restored and the values are substituted instead of the names declared as DOMAIN PARAMETERS, the names of iterated variables are substituted for the corresponding names of the variables-results ( from the previous or current step of iteration).
Line of Table of operators body has the form:
| sequence of token codes |
3.14Table of input-output formats
Table of input-output formats is used for holding attributes of input-output for input-variable and output-variable.
Line of Table of input-output formats has the form:
|
| name-variable | name-domain | attribute | … | attribute |
<statement number>::=<integer>
<name-variable>::=<token code>
<name-domain>::=<token code> OR ‘S’
<attribute>::=<sequence of token codes>
This information means that variable with name <name-variable> on domain <name-domain> (if <name-variable> - name of scalar variable, then <name-domain>=’S’) is input-variable or output-variable in the operator with <statement number> and has attributes <attribute>.
3.15Data dependencies graph (DDG)
DDG G(V,E) is an hierarchical oriented graph. V is a set of graph nodes, each nodes corresponds to some Norma operators, iteration or declaration of input and output variables. E is a set of edges reflecting variables dependencies: if variable X depends on variable Y then there exists edge e from X to Y.
All Norma iteration unit for special nodes (iteration-nodes) are substituted. Iteration-nodes is a subgraph of DDG graph.
All Norma ordered groups (Norma statements groups for which sequential computing mode is defined) for special nodes (ordered-groups-nodes) are substituted.
DDG is represented by the following data structure: for each node vV the line of dependencies is defined . It contains the nodes of DDG, which v depends on.
|
| dependency-node | … | dependency-node |
<dependency-node>::=<node>
<graph-node>::=<node>
<node>::=<statement number> OR <iteration number> OR <ordered group number>
3.16Reduced data dependencies graph (RDDG)
RDDG is graph of graph DDG in which search for maximum strongly connected subgraphs (MSCS) is performed and all MSCS for special nodes are substituted.
MSCS is strongly connected subgraph of graph DDG, which is not contained in any other strongly connected subgraph of graph DDG.
Therefore RDDG is a hierarchical oriented acyclic graph G(V,E) which consists of MSCS-nodes, iteration-nodes, ordered-groups-nodes and simple nodes (other nodes).
RDDG is represented by the following data structure: for each node vV the line of dependencies is defined . It contains the nodes RDDG, which v depends on.
|
| r-dependency-node | … | r-dependency-node |
<r-dependency-node>::=<node>
<r-graph-node>::=<node>
<node>::=<statement number> OR <iteration number> OR <ordered group number> OR <MSCS number>
3.17List of MSCS
MSCS is strongly connected subgraph of graph DDG, which is not contained in any other strongly connected subgraph of graph DDG.
Element of List of MSCS is represented by the following data structure:
|
| statement number | … | statement number |
3.18List for parallel layer scheme representation
Parallel layer scheme is the result of reduced data dependencies graph (RDDG) partial ordering. If an edge from P to Q (P,Q from V) exists (in other words Q is used to calculate P), then P>Q (Q must be calculated earlier than P).
Computations corresponding to RDDG nodes of the same layer may be parallel and independent. Passage from a current layer to the next one is performed after all the computations of the current layer have been performed.
Parallel layer scheme is represented by the following data structure:
|
| layer | … | layer |
Structure of <layer> element:
|
| node | … | node |
<layer-number>::=<integer>
<node>::=<statement number> OR <iteration number><parallel layer scheme> OR
<ordered group number> OR <MSCS number>
3.19Table of distributed variables
Table of distributed variables is used for holding information about variables need required source of memory at every processor.
Line of Table of distributed variables has the form:
| name-variable | name-index | range | name-index | range |
<name-variable>::=<token code>
<name-index>::=<token code>
<range>::=<integer><integer>
This information means that variable <name-variable> is distributed among the processors by indexes <name-index>, volume of memory in each processor by the given index are defined by field <range>.
3.20Table of shadow variables
Table of shadow variables is used for holding information about variables need additional space for the elements that have to be moved in from neighbouring processors (‘shadow edges’, see document ‘Fortran DVM. Language description’, SHADOW directive description) in distributing memory on every processor.
Line of Table of shadow variables has the form:
| name-variable | name-index | low-shadow | high-shadow | name-index | low-shadow | high-shadow |
<name-variable>::=<token code>
<name-index>::=<token code>
<low-shadow>::=<integer>
<high-shadow>::=<integer>
This information means that variable <name-variable> need additional memory by indexes <name-index>, size of extension on the given index <low-shadow> on the left and <high-shadow> on the right.
3.21Table of remote variables
Table of remote variables contains information about program statements, which have remote references to distributed arrays (see document ‘Fortran DVM. Language description’, REMOTE_ACCESS directive description).
Line of Table of remote variables has the form:
| statement number | name-variable | index-expression | name-index | range | name-index | range |
<name-variable>::=<token code>
<index-expression>::=<sequence of token codes>
<name-index>::=<token code>
<range>::=<integer><integer>
This information means that in operator with number <statement number> values of variable <name-variable>[<index-expression>] are required, ranges of distributed indexes alteration <name-index> are defined by field <range>.
3.22Intermediate representation of Fortran DVM programs
List FORT of the type given below is used for Intermediate representation of Fortran DVM program:
|
| fortran-statement | … | fortran-statement |
Structure of <fortran-statement> element:
| ‘C’ | comment | - | line-comment |
| ‘CHPF’ | HPF-comment | - | HPF-line-comment |
| ‘CDVM’ | DVM-comment | - | DVM-line-comment |
| label | CONTINUE | - | operator CONTINUE |
| DO label name-index b-value e-value step | - | operator DO label name-index=b-value,e-value,step | |
| IF logic-expression label | - | operator IF (logic-expression) GOTO label | |
| GOTO label | - | operator GOTO label | |
| CALL name-subroutine list-parameters | - | operator CALL name (list-parameters) | |
| READ chan-number label read-list | - | operator READ (chan-number,label)read-list | |
| WRITE chan-number label write-list | - | operator WRITE (chan-number,label)write-list | |
| label | FORMAT format-list | - | operator label FORMAT( format-list) |
| IFTHEN logic-expression operators | - | operator IF logic-expression THEN operators ENDIF | |
| IF_THEN_ELSE logic-expression (operators)(operators) | - | operator IF logic-expression THEN operators ELSE operators ENDIF | |
| PROGRAM name-program | - | operator PROGRAM | |
| SUBROUTINE name-subroutine list-parameters | - | operator SUBROUTINE name (list-parameters) | |
| type | FUNCTION name-function list-parameter | - | operator type FUNCTION name (list-parameters) |
| declaration declaration-list | - | declaration of variables | |
| EXTERNAL external-list | - | declaration of externals | |
| DATA data-list | - | operator DATA | |
| assignment | - | operator assignment | |
| RETURN | - | operator RETURN | |
| END | - | operator END | |
| STOP | - | operator STOP |
<comment>::=<string>
statement number















