Complete redesign of environment model and declaration parser. This
authorChris Hanson <org/chris-hanson/cph>
Sat, 2 Jan 1993 07:33:39 +0000 (07:33 +0000)
committerChris Hanson <org/chris-hanson/cph>
Sat, 2 Jan 1993 07:33:39 +0000 (07:33 +0000)
commitaf5215b750b9491af517dab3b3c25965f2c9edf5
tree0d2091a1215591a1505f6b9c8c661a7b290ae26a
parent1267f634e865f1c236d278e360d9492b490a41cc
Complete redesign of environment model and declaration parser.  This
was prompted by a bug that had been present since the original design;
the bug was inherent in the design, hence the need for a redesign.
The new design has the following features:

* The old design used a two-level environment model for the top-level
  environment, in which imported and global bindings were
  distinguished from top-level bindings appearing in the file.  The
  new design uses a single top-level environment for all bindings.
  This is the change fixed the bug, but introduced performance
  problems because the two-level design had a special hack for the
  global environment; the performance problems were fixed by:

* The new design uses a hash table to hold the bindings in (the model
  of) an environment frame when the number of bindings exceeds a
  preset threshold.  This allows very large environment frames to have
  reasonable access times, while avoiding the time and space overhead
  of the hash table for small environment frames; typically only a few
  frames will use the hash table mechanism.  The hash table uses open
  addressing with double hashing.

* Because ".ext" files are internal data structures that are written
  to a file, old ".ext" files are incompatible with the new scode
  optimizer.  In order to prevent lossage, ".ext" files have a new
  format, which contains a version number.  When the scode optimizer
  encounters an old ".ext" file, or a new one with the wrong version
  number, it will emit a warning and ignore it.

* Code that supported special "error combinations" has been removed,
  since these are no longer used.

* Code that generated ".unf" files has been removed.  Since several
  procedures with semi-public interfaces accept arguments or return
  values relating to these files, the procedures ignore such arguments
  and return dummy values.  The global variable SFU? has been
  eliminated.
16 files changed:
v7/src/sf/chtype.scm
v7/src/sf/copy.scm
v7/src/sf/emodel.scm
v7/src/sf/free.scm
v7/src/sf/make.scm
v7/src/sf/object.scm
v7/src/sf/pardec.scm
v7/src/sf/reduct.scm
v7/src/sf/sf.pkg
v7/src/sf/subst.scm
v7/src/sf/tables.scm
v7/src/sf/toplev.scm
v7/src/sf/usiexp.scm
v7/src/sf/xform.scm
v8/src/sf/make.scm
v8/src/sf/toplev.scm