Abstract
We propose to measure the efficiency of any implementation of the λ-calculus as a function of a new parameter v, that is itself a function of any λ-expression.
Complexity is expressed here as a function of v just as runtime is expressed as a function of the input size n in ordinary analysis of algorithms. This enables implementations to be compared for worst case efficiency.
We argue that any implementation must have complexity Ω(v), i.e. a linear lower bound. Furthermore, we show that implementations based upon Turner Combinators or Hughes Super-combinators have complexities 2Ω(v), i.e. an exponential lower bound.
It is open whether any implementation of polynomial complexity, v O(1), exists, although some implementations have been implicitly claimed to have this complexity.
This research was partially carried out, while visiting Dartmouth College, New Hampshire
This research was partially carried out, while supported by the Danish Natural Science Research Council (grant No. 11-7991) and while supported by the ESPRIT II Basic Research Actions Program of the EC under contract No. 3075 (project ALCOM).
Preview
Unable to display preview. Download preview PDF.
References
Barendregt, H. P., The Lambda Calculus. Its Syntax and Semantics. North Holland, 1981.
Burton, F. W., A Linear Space Translation of Functional Programs to Turner Combinators. Information Processing Letters, 14 (1982), pp. 201–204.
de Bruijn, N. G., Lambda Calculus Notation with Nameless Dummies, a Tool for Automatic Formula Manipulation. Indag Math, 34 (1972), pp. 381–392.
Church, A., A Set of Postulates for the Foundation of Logic. Annals of Math. 33, 2nd series (1932), pp. 346–366.
Curry, H. B. and Feys, R. Combinatory Logic, Vol. 1. North Holland, 1958.
Field, J., On Laziness and Optimality in Lambda Interpreters: Tools for Specification and Analysis. In [PoPL90], pp. 1–15.
the Handbook of Theoretical Computer Science, vol A (ed. J. van Leeuwen). Elsevier, Amsterdam, 1990.
Hughes, R. J. M., Super Combinators: A New Implementation Method for Applicative Languages. In Proceedings of the 1982 ACM Symposium on Lisp and Functional Programming, pp.1–10.
Hughes, R. J. M., The Design and Implementation of Programming Languages. Ph.D. Thesis, Oxford University, 1984. (PRG-40)
Kennaway, J. R. and Sleep, M. R., Variable Abstraction in O(n log(n)) Space. Information Processing Letters, 24 (1987), pp. 343–349.
Klop, J. W., Combinatory Reduction Systems. Mathematical Centre Tracts 127. Mathematisch Centrum, Amsterdam, 1980.
Lamping, J., An Algorithm for Optimal Lambda Calculus Reduction. In [PoPL90], pp. 16–30.
Lévy, Jean-Jacques, Optimal Reductions in the Lambda-Calculus. In Seldon, J. P. and Hindley, J. R. (editors), To H. B. Curry: Essays on Combinatory Logic, Lambda Calculus and Formalism, Academic Press, 1980, pp. 159–191.
Lévy, Jean-Jacques, Sharing in the Evaluation of Lambda Expressions. In Fuchi,K. and Kott,L. (editors), Programming of Future Generation Computers II, North Holland, 1988, pp. 183–189.
Noshita, K., Translation of Turner Combinators in O(n log(n)) Space. Information Processing Letters, 20 (1985), pp. 71–74.
Proceedings of Seventeenth Annual ACM Symposium on Principles of Programming Languages. ACM, New York, 1990.
Révész, G. E., Lambda-Calculus, Combinators and Functional Programming. Cambridge University Press, 1988.
Rosser, J. B., Highlights of the History of the Lambda-Calculus. Annals of the History of Computing 6 (1984), pp. 337–349.
Schönfinkel, M., Über die Bausteine der mathematischen Logik. Matematische Annalen, 92 (1924), pp. 305–316.
Schönhage, A., Storage Modification Machines. SIAM Journal on Computing 9 (1980), pp. 490–508.
Schönhage, A., A Nonlinear Lower Bound for Random-Access Machines under Logarithmic Cost. Journal of the ACM 35 (1988), pp. 748–754.
Staples, J., Two-Level Expression Representation for Faster Evaluation. In Ehrig,H., Nagl,M. and Rozenberg,G. (editors), Proceedings from 2nd International workshop “Graph Grammars and their Application to Computer Science”. Springer Verlag (LNCS 153), 1983, pp. 392–404.
Turner, D. A., Another Algorithm for Bracket Abstraction. The Journal of Symbolic Logic 44 (1979), pp. 267–270.
Turner, D. A., New Implementation Techniques for Applicative Languages. Software: Practice & Experience. 9 (1979), pp. 31–49.
Author information
Authors and Affiliations
Editor information
Rights and permissions
Copyright information
© 1991 Springer-Verlag Berlin Heidelberg
About this paper
Cite this paper
Frandsen, G.S., Sturtivant, C. (1991). What is an efficient implementation of the λ-calculus?. In: Hughes, J. (eds) Functional Programming Languages and Computer Architecture. FPCA 1991. Lecture Notes in Computer Science, vol 523. Springer, Berlin, Heidelberg. https://doi.org/10.1007/3540543961_14
Download citation
DOI: https://doi.org/10.1007/3540543961_14
Published:
Publisher Name: Springer, Berlin, Heidelberg
Print ISBN: 978-3-540-54396-1
Online ISBN: 978-3-540-47599-6
eBook Packages: Springer Book Archive