perm filename CVARS[CMP,SYS] blob sn#012116 filedate 1973-07-03 generic text, type T, neo UTF8
	Brief Description of Compiler Global Variables

ACS is  a  map  of  the  contents  of  the  accumualtors  during  the
compilation.  An entry in this may be NIL, or a doted pair.  If it is
NIL it indicates that nothing is known  about  the  contents  of  the
accumualtor  If  it  is  a  dotted  pair with null cdr then it is the
current value of a variable.    If its cdr is numeric, it  represents
the  value  of  a variable at some previous "time".     If its cdr is
"DUP", it is a duplicate of the current value of  a  variable.     If
its  cdr  is  "QT" then it is a quoted expression.      If its cdr is
"TAKEN" then it is an ad hoc value which cannot  normally  be  moved,
damaged or even seen.

ALLACS  is  a  default  map  with  ones set in every position.     It
indicates that every argument accumulator is affected by  a  function

ALLFUNS is a list of all the fuctions defined in the compilation of a

ARRAYAC is the accumualtor which is used for the computation  of  the
argument to the special array access routine.

CCLST  is  a  list  of  partial  results  which  are  cars or cdrs of
variables.   Each  entry  contains  a  name  for  a  partial  result,
followed  by a function name CAR, CDR, CADR etc. followed by the item
to which this fucntion must be applied.

CODESIZE is simply a count of  how  many  words  of  code  have  been

CONSTSIZE is a count of how many constants have been generated.

CTAG  is  a  tag  which is the exit to an n-tuple in a COND.  In many
cases such a tag will only be jumped to from one place, and cannot be
dropped  in  to.    In  such  cases CTAG helps to expedite this jump,
avoiding the usual  loss  of  knowledge  or  the  acs  which  usually
accompanies a jump.

CURBIND is a list of the variables a a point in the computation which
are currently bound by local lambdas or progs, along with the name by
which  they are being called.  Variables are normally called by their
own names, unless the same variable is bound twice in  the  function,
in  which case the second occurrence is sytematically renamed and the
old and new names entered as a dotted pair on this list.

EXIT is the tag which is the exit from a PROG.  It is  passed  around
free  and used in the compilation of a cond to expedite the case of a
conditional return.

EXITN is the exit from a prog which returns NIL and is used similarly
to EXIT.

FARGAC is the ac used for the argument of an FSUBR or FEXPR.

FOUNDFREE is a list of all variables found  free  in  the  expression
being compiled. These are a subset of the special variables.

FUNNAME is the name of the function being compiled.

GENFUNS  is  a  list  of  the  names of the functions which have been
generated from explicit lambda expressions used as arguments  to  the
functions FUNCTION or *FUNCTION.

GOLIST  is  a  list  associated  with  a  prog  of  all  tags and the
equivalent tags to be used in the Lap output code.

GOTABAC is the ac to be used for the arguments of computed GOs.

INDEV is the default device from which the compilers input is  to  be

INPROG  is  a  flag  saying  whether  the  expression currently being
compiled is inside a prog.  If this flag is not set a  GO  or  RETURN
will cause an error.

LASTOUT  is  a  one instruction output buffer.   Instructions in this
buffer are occasionally deleted or modified.

LDLST is the list of items waiting  to  be  loaded  as  arguments  to

LINCNT  is the number of lines which have been printed on the current

LISTING is the name of a device to be used  for  the  messages  which
would normally be sent to the console.

LOCVARS is a list of all the local variables encountered in pass one,
together with a notation of the count at which they were last seen.

MINDEPTH is the shortest that the stack may  be  allowed  to  get  in
order  that  it may be restored to the length requred to jump to some

MSGCHAN is the channel used for the messages output by the compiler.

NACS  is  the number of acs which may be used for function arguments.
It is the length of ACS.

OUTDEV is the device to which the compiler's output is directed.

OUTEXT is the extension which will be added to the name of the  input
fill to get the name of the output file.

P1CNT is the count kept in pass one.  This count begins at one and is
incremented each time any variable occurs.  It is also incremented at
selected  places  in  functions  which branch, though this may not be
necessary.  Since no two occurences of a variable may have  the  same
count, the count may be used to refer to old values of variables.

P2CNT  is the count kept in pass two.  It should at all points in the
computation parallel the corresponding values of P1CNT.

P1SCNT is a count saved in pass one at the  beginning  of  functions,
such  as  PROG,  which destroy the partially ordered flow of control.
After the funtion has been processed, the  counts  of  all  variables
seen  after P1SCNT are raised to the value of P1CNT at the end of the

PAGEHEIGHT is the height of pages on the current output device.

PAGEWIDTH is the width of pages on the current output device.

PDL is a map of the contents of the push down  list.    The  possible
entries in this list are described under ACS.

PDLDEPTH is the current length of the PDL.

PRGSPFLG is a flag indicating that a PROG binds special variables.

PROGSW  is  a switch indicating that the variables of a PROG have yet
to be put on the stack.  This is part of a mechanism  which  attempts
to  optomise  the code at the beginning of a PROG by not pushing NILS
on the stack for variables which are set before they  are  referenced
and before any branching occurs.

PROGVARS  is a list of those local variables of a prog which have not
yet been given slots  on  the  stack.   This  is  part  of  the  same
optimizatin cited under PROGSW.

PRSSL  is  a  copy  of the stack just after all of the prog variables
have been pushed.

PVR stands for the prog value register.  This is the place  in  which
the  value  of  the current PROG will be returned.  It is passed down
free to the function which compiles return.

RSL is a copy of the slotlist at the time a jump to CTAG was output.

SHOWNAMES is a switch indicating that the name of each  function  the
compiler processes should be typed on the message device.

SPECVARS  is  a  list  of  all  special  variables encountered in the
fuction definition during pass one.

TRACELIST is a list of expressions which will be evaluated each  time
an instruction is output and printed on the output listing.

UNDFUNS is a list of all functions call before they are defined.

VALUEAC is the ac in which the value of a function is returned.

VARLIST  is  a  list  of  partial results which have been found to be
equal to others by being car and cdrs of the same things.  This  list
is  used  to  protect  items  which  would normally have passed their

VGO is the tag which marks the begining  of  the  despatch  code  for
computed GOs.