Hostname: page-component-7479d7b7d-t6hkb Total loading time: 0 Render date: 2024-07-12T14:08:18.675Z Has data issue: false hasContentIssue false

π-RED+ An interactive compiling graph reduction system for an applied λ-calculus

Published online by Cambridge University Press:  07 November 2008

Dietmar Gärtner
Affiliation:
Christian-Albrechts-Universität Kiel, Institut für Informatik, D-24105 Kiel, Germany e-mail: wk@informatik.uni--kiel.d400.de
Werner E. Kluge
Affiliation:
Christian-Albrechts-Universität Kiel, Institut für Informatik, D-24105 Kiel, Germany e-mail: wk@informatik.uni--kiel.d400.de
Rights & Permissions [Opens in a new window]

Abstract

Core share and HTML view are not available for this content. However, as you have access to this content, a full PDF is available via the ‘Save PDF’ action button.

This paper describes a compiling graph reduction system which realizes the reduction semantics of a fully-fledged applied λ-calculus. High-level functional programs are conceptually executed as sequences of program transformations governed by full β-reductions. They may be carried out step-by-step, and intermediate programs may be displayed in high-level notation, rendering the system suitable for interactive program design, high-level debugging, and also for teaching basic programming language concepts and language interpretation. Run-time efficiency for production runs is achieved by means of an abstract stack machine ASM which serves as an intermediate level of code generation. It employs multiple stacks for reasonably fast function calls, optimized tail-end recursions, and earliest possible releases of subgraphs that are no longer needed. The ASM involves an interpreter if and only if potential naming conflicts need to be resolved when reducing partial function applications.

Type
Articles
Copyright
Copyright © Cambridge University Press 1996

References

Backus, J. (1978) Can programming be liberated from the von Neumann style? A functional style and its algebra of programs, Comm. ACM 21(4): 613643.Google Scholar
Berkling, K. J. (1974) Reduction languages for reduction machines, Proc. 2nd Int. Symp. on Comp. Arch., pp. 133140. ACM/IEEE.CrossRefGoogle Scholar
de Bruijn, N. G. (1972) Lambda-calculus notation with nameless dummies. A tool for automatic formula manipulation with application to the Church–Rosser theorem, Indagationes Mathematicae 34: 381392.Google Scholar
Cardelli, L. and McQueen, D. (1983) The Functional Abstract Machine, The ML/LCF/HOPE Newsletter, AT&T Bell Labs, Murray Hill, NJ.Google Scholar
Church, A. (1941) The Calculi of λ-Conversion. Princeton University Press.Google Scholar
Cousineau, G., Curien, P.-L. and Mauny, M. (1987) The Categorial Abstract Machine, Science of Computer Programming (8): 173202.Google Scholar
Curry, H. B. (1936) Functionality in combinatory logic, Proc. Nat. Academy of Science USA 20: 584590.Google Scholar
Fairbairn, J. and Wray, S. C. (1988) TIM: a simple lazy abstract machine to execute super-combinators, Proc. Conf. on Functional Programming and Computer Architecture: Lecture Notes in Computer Science 274, pp. 3445. Springer-Verlag.Google Scholar
Gaertner, G., Kimms, A. and Kluge, W. (1992) π-RED+– a compiling graph reduction system for a full-fledged λ-calculus, Proc. 4th Int. Workshop on the Parallel Implementation of Functional Languages, Aachener Informatik Berichte Nr. 92–19.Google Scholar
Goldson, D. (1994) A symbolic calculator for non-strict functional programs, The Computer Journal 37(3): 177187.Google Scholar
Harper, E., MacQueen, D. and Milner, R. (1986) Standard ML, Laboratory for Foundations of Computer Science, University of Edinburgh.Google Scholar
Hindley, J. R. and Seldin, J. P. (1986) Introduction to Combinators and λ-Calculus, Cambridge University Press (London Mathematical Society Student Texts).Google Scholar
Hudak, P., Peyton Jones, S., Wadler, P., Boutel, B., Fairbairn, J., Fasel, J., Hammond, K., Hughes, J., Johnsson, T., Kieburtz, D., Nikhil, R., Partain, W. and Peterson, J. (1992) Report on the Programming Language Haskell, ACM SIGPLAN Notices 27(5): 1742.Google Scholar
Hudak, P. and Goldberg, B. (1985) Serial combinators: optimal grains for parallelism, Proc. Conf. on Functional Programming and Computer Architecture: Lecture Notes in Computer Science 201, pp. 382399. Springer-Verlag.Google Scholar
Hughes, R. J. M. (1982) Super-combinators – a new implementation technique for applicative languages, Proc. ACM Conf. on LISP and Functional Programming, pp. 119. Pittsburgh, PA,Google Scholar
Johnson, T. (1985) Lambda lifting: transforming programs to recursive equations, Proc. Conf. on Functional Programming and Computer Architecture: Lecture Notes in Computer Science 201,pp. 190203. Springer-Verlag.Google Scholar
Johnsson, T. (1984) Efficient compilation of lazy evaluation, SIGPLAN Compiler Construction Conference,Montreal, Quebec.Google Scholar
Kluge, W. (1994) Programming the Reduction System π-RED, Internal Report Nr. 9419, Institut für Informatik und Praktische Mathematik, CAU Kiel/Germany.Google Scholar
Peyton Jones, S. L. (1987) The Implementation of Functional Programming Languages, Prentice Hall.Google Scholar
Peyton Jones, S. L. (1992) Implementing lazy functional languages on stock hardware: the Spineless Tagless G-Machine, J. Functional Programming 2(2): 127202.CrossRefGoogle Scholar
Plasmeijer, R. and van Eekelen, M. (1993) Functional Programming and Parallel Graph Rewriting, Addison-Wesley.Google Scholar
Schmittgen, C., Bloedorn, H. and Kluge, W. (1992) π-RED' – a graph reducer for a full-fledged λ-calculus, New Generation Computing 10(2): 173195.Google Scholar
Turner, D. A. (1976) A new implementation technique for applicative languages, Software–Practice and Experience 9(1): 3149.CrossRefGoogle Scholar
Turner, D. A. (1986) An overview of Miranda, SIGPLAN Notices 21(12): 158166.Google Scholar
Allegro CL User Guide (1992) Vol. 1, Version 4.1, Franz Inc.Google Scholar
Sun Common LISP 4.0 User's Guide (1990) SUN Microsystems Inc.Google Scholar
Submit a response

Discussions

No Discussions have been published for this article.