A model and stack implementation of multiple environments
- 1 October 1973
- journal article
- Published by Association for Computing Machinery (ACM) in Communications of the ACM
- Vol. 16 (10) , 591-603
- https://doi.org/10.1145/362375.362379
Abstract
Many control and access environment structures require that storage for a procedure activation exist at times when control is not nested within the procedure activated. This is straightforward to implement by dynamic storage allocation with linked blocks for each activation, but rather expensive in both time and space. This paper presents an implementation technique using a single stack to hold procedure activation storage which allows retention of that storage for durations not necessarily tied to control flow. The technique has the property that, in the simple case, it runs identically to the usual automatic stack allocation and deallocation procedure. Applications of this technique to multitasking, coroutines, backtracking, label-valued variables, and functional arguments are discussed. In the initial model, a single real processor is assumed, and the implementation assumes multiple-processes coordinate by passing control explicitly to one another. A multiprocessor implementation requires only a few changes to the basic technique, as described.Keywords
This publication has 12 references indexed in Scilit:
- Extensible control structuresPublished by Association for Computing Machinery (ACM) ,1973
- Requirements for advanced programming systems for list processingCommunications of the ACM, 1972
- On implementation of label, variablesCommunications of the ACM, 1971
- Some examples of the use of function-producing functionsPublished by Association for Computing Machinery (ACM) ,1971
- The function of FUNCTION in LISP or why the FUNARG problem should be called the environment problemACM SIGSAM Bulletin, 1970
- GEDANKEN—a simple typeless language based on the principle of completeness and the reference conceptCommunications of the ACM, 1970
- A LISP garbage-collector for virtual-memory computer systemsCommunications of the ACM, 1969
- Nondeterministic AlgorithmsJournal of the ACM, 1967
- Backtrack ProgrammingJournal of the ACM, 1965
- Recursive ProgrammingNumerische Mathematik, 1960