A Preliminary Exploration of
Optimized Stack Code Generation

Philip J. Koopman, Jr

Draft copy of paper published in:
Journal of Forth Applications and Research, 1994, 6(3) pp. 241-251


This paper presents an experimental code generator that performs intra-block stack scheduling for a stack-based execution model. For small test programs, 91% to 100% of redundant local variable accesses were eliminated using this compiler. Compiled intra-block stack scheduling and hand-performed global stack scheduling show that significant opportunities exist to keep temporary variable values on the expression evaluation stack when compiling conventional languages.

HTML paper (49K bytes)

Adobe Acrobat paper (64KB)

Postscript paper (182K bytes)

Also, see Anton Ertl's publications based on this work at http://www.complang.tuwien.ac.at/projects/forth.html ( the papers listed under Optimization for Stack machines)


Phil Koopman -- koopman@cmu.edu