<project.out>

Disclaimer: This description may not always be correct up to the last "new line" character or exact number of "=" signs or white spaces.
Second Disclaimer: If something strikes you as not being useful or as irrelevant to you, you are probably right... :-)

In this file, the following information is stored:

Read: Directory scanpars2 File Parser.cc Function Load
Write: Directory scanpars2 File Parser.cc Function Save

Format

For the description of the format, we use the following symbols:
 
[...] ... optional construct
{...} ... possible repetition of a construct
  |   ... alternative
-->   ... definition of a non-terminal
<nl>  ... new line character
\"    ... quote (or inch) sign


This file is built as follows:

File  -->
SymbolTable:<nl><nl><SymTab>SymbolTable END<nl><nl>
[MainProgram:<nl><nl><LaNodes><nl><nl>]
[Functions:<nl><nl><FctDecls><nl><nl>]
[Dependencies:<nl><nl><DummyDeps><nl><nl>]
// number of indices <NrInd><nl>
// number of blobs   <NrBlobs><nl>
// number of stmnts  <NrStats><nl>
// number of arrays  <NrArrays><nl>
// last LaNode ID    <lastLaNodeID><nl><nl><nl>
<PrettyNames>
The entries NrInd, NrBlobs, NrStats, NrArrays, lastLaNodeID are integers giving the corresponding numbers. The other constructs are built as follows:

Symbol-Table (<SymTab>)

Syntax

SymTab  -->
{<FrameDesignator>
{<SymTabEntry>}
}
FrameDesignator  -->
================<nl>
// frame <frameNr><nl>
================<nl>
SymTabEntry  -->
================<nl>
// lexem        <lexem><nl>
// token        <token><nl>
// type         <type><nl>
// number       <number><nl>
// indices      <indices><nl>
// level        <level><nl>
// intent       <intent><nl>
// basictype    <basictype><nl>
// identify     <identity><nl>
// status       <status><nl>
// next         <ptrInfo><nl>
// leftchild    <ptrInfo><nl>
// rightchild   <ptrInfo><nl>
<bounds>
bounds  --> nobounds |
{
===========<nl>
<LaExpr>
}
LaExpr  -->
<NumInd><nl>{<integer><nl>}
<Const><nl>
<NumBlob><nl>{<integer><nl>}
<Denom><nl>
<nextLaExpr><nl>
nextLaExpr --> 0|1

Semantics

The symbol table is divided into frames. Each user defined function/procedure and the main-program has an own frame. The `main`-program owns frame 1 and a user defined function/procedure with number n owns the frame (n+1); a predefined function/procedure with number -n owns a frame -n-1. For predefined functions, the default behaviour is to take no or only input arguments; for these functions, no frame is stored.

A symbol table entry contains the following information:

Main Program/Functions (<LaNodes>/<FctDecls>)

Syntax

The main program is given by a sequence of LaNodes:
LaNodes  --> {<LaNode>}
FctDecls --> {<LaNode_verb>}
Normally, the output format is "compressed" (i.e. not really human readable), there is also a "verbose-save-mode" that is described below. The normal format is:
LaNode      -->  [InfoVect: {<ModNr>} -1]<nl>[{ModTag}] <LaNodeBase>
LaNodeBase  -->  <ID> <occ> <type> <name> <state> <stmnt> <op> <Tstmnt> <step> <up> <low>
                 <cond> <indices> <children> <elsechild> <arguments> <next> \"<label>\" #
This output format will be used in verbose-save-mode:
LaNode_verb  -->
================<nl>
// typ          <type><nl>
// name         <name><nl>
// state        <state><nl>
// stmnt        <stmnt><nl>
// ID           <ID><nl>
// occ_ID       <occ><nl>
// op           <op><nl>
// Tstmnt       <Tstmnt><nl>
// step         <step><nl>
// up           <up><nl>
// low          <low><nl>
// cond         <cond><nl>
// indices      <indices><nl>
// children     <children><nl>
// elsechild    <elsechild><nl>
// arguments    <arguments><nl>
// next         <next><nl><nl>
This output format is used for functions/procedures.

Semantics

A LaNode contains the following information: If a LaNode has a child in one of the pointer fields
  1. step
  2. up
  3. low
  4. cond
  5. indices
  6. children
  7. elsechild
  8. arguments
  9. next
the entry saved in the file is 1 for a child node that is present and 0 if no child node for that field is present; the corresponding child nodes are saved in preorder search with the different LaNodes (step/up/low/...) sorted in the same order as the information whether these nodes are present.
 

Dependencies (<DummyDeps>)

Syntax

DummyDeps  -->  {LaDep}<nl>
LaDep  -->
// rows    <rows><nl>
// columns <cols><nl>
// denom   <denom><nl>
// matrix<nl>
{{<integer>}<nl>}
// first dependent statement   <src><nl>
// second dependent statement  <dest><nl>
// next <nextDummyDep><nl>
nextDummyDep  --> 0|1

Semantics

For each user defined dependence, a LaDep is created that holds the rows and columns of the matrix representing the h-transformation in the correspondig entry; denom is the common denominator of the complete matrix; the matrix itself (in homogeneous coordinates) is then stored row-by-row on separate lines (with only integer entries). src is the number of the source statement, dest the number of the destination statement of the dependence. next is a pointer to the next user defined dependence (stored just like the pointers in LaNodes).
 

Symbol Table, Part II (<PrettyNames>)

Syntax

PrettyNames  -->
{<FrameDesignator>
{<origName> -> <prettyName>;<nl>}
}

Semantics

For each frame, the names of identifiers is stored in the origName fields; symbol table entries may also have an entry in their "pretty" field which indicates that this pretty name is to be preferred for printing. Pretty names are set by targout.
 
Andreas Dischinger, 26 Nov 1997; revised: Peter Faber, 2001-10-10