Skip to main content

What is an efficient implementation of the λ-calculus?

  • Conference paper
  • First Online:
Functional Programming Languages and Computer Architecture (FPCA 1991)

Part of the book series: Lecture Notes in Computer Science ((LNCS,volume 523))

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).

This is a preview of subscription content, log in via an institution to check access.

Access this chapter

Institutional subscriptions

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

References

  1. Barendregt, H. P., The Lambda Calculus. Its Syntax and Semantics. North Holland, 1981.

    Google Scholar 

  2. Burton, F. W., A Linear Space Translation of Functional Programs to Turner Combinators. Information Processing Letters, 14 (1982), pp. 201–204.

    Google Scholar 

  3. de Bruijn, N. G., Lambda Calculus Notation with Nameless Dummies, a Tool for Automatic Formula Manipulation. Indag Math, 34 (1972), pp. 381–392.

    Google Scholar 

  4. Church, A., A Set of Postulates for the Foundation of Logic. Annals of Math. 33, 2nd series (1932), pp. 346–366.

    Google Scholar 

  5. Curry, H. B. and Feys, R. Combinatory Logic, Vol. 1. North Holland, 1958.

    Google Scholar 

  6. Field, J., On Laziness and Optimality in Lambda Interpreters: Tools for Specification and Analysis. In [PoPL90], pp. 1–15.

    Google Scholar 

  7. the Handbook of Theoretical Computer Science, vol A (ed. J. van Leeuwen). Elsevier, Amsterdam, 1990.

    Google Scholar 

  8. 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.

    Google Scholar 

  9. Hughes, R. J. M., The Design and Implementation of Programming Languages. Ph.D. Thesis, Oxford University, 1984. (PRG-40)

    Google Scholar 

  10. Kennaway, J. R. and Sleep, M. R., Variable Abstraction in O(n log(n)) Space. Information Processing Letters, 24 (1987), pp. 343–349.

    Google Scholar 

  11. Klop, J. W., Combinatory Reduction Systems. Mathematical Centre Tracts 127. Mathematisch Centrum, Amsterdam, 1980.

    Google Scholar 

  12. Lamping, J., An Algorithm for Optimal Lambda Calculus Reduction. In [PoPL90], pp. 16–30.

    Google Scholar 

  13. 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.

    Google Scholar 

  14. 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.

    Google Scholar 

  15. Noshita, K., Translation of Turner Combinators in O(n log(n)) Space. Information Processing Letters, 20 (1985), pp. 71–74.

    Google Scholar 

  16. Proceedings of Seventeenth Annual ACM Symposium on Principles of Programming Languages. ACM, New York, 1990.

    Google Scholar 

  17. Révész, G. E., Lambda-Calculus, Combinators and Functional Programming. Cambridge University Press, 1988.

    Google Scholar 

  18. Rosser, J. B., Highlights of the History of the Lambda-Calculus. Annals of the History of Computing 6 (1984), pp. 337–349.

    Google Scholar 

  19. Schönfinkel, M., Über die Bausteine der mathematischen Logik. Matematische Annalen, 92 (1924), pp. 305–316.

    Google Scholar 

  20. Schönhage, A., Storage Modification Machines. SIAM Journal on Computing 9 (1980), pp. 490–508.

    Google Scholar 

  21. Schönhage, A., A Nonlinear Lower Bound for Random-Access Machines under Logarithmic Cost. Journal of the ACM 35 (1988), pp. 748–754.

    Google Scholar 

  22. 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.

    Google Scholar 

  23. Turner, D. A., Another Algorithm for Bracket Abstraction. The Journal of Symbolic Logic 44 (1979), pp. 267–270.

    Google Scholar 

  24. Turner, D. A., New Implementation Techniques for Applicative Languages. Software: Practice & Experience. 9 (1979), pp. 31–49.

    Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Editor information

John Hughes

Rights and permissions

Reprints 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

Publish with us

Policies and ethics