Skip to main content Accessibility help
×
×
Home

Small-step and big-step semantics for call-by-need

  • KEIKO NAKATA (a1) and MASAHITO HASEGAWA (a2)
Abstract

We present natural semantics for acyclic as well as cyclic call-by-need lambda calculi, which are proved equivalent to the reduction semantics given by Ariola and Felleisen (J. Funct. Program., vol. 7, no. 3, 1997). The natural semantics are big-step and use global heaps, where evaluation is suspended and memorized. The reduction semantics are small-step, and evaluation is suspended and memorized locally in let-bindings. Thus two styles of formalization describe the call-by-need strategy from different angles. The natural semantics for the acyclic calculus is revised from the previous presentation by Maraist et al. (J. Funct. Program., vol. 8, no. 3, 1998), and its adequacy is ascribed to its correspondence with the reduction semantics, which has been proved equivalent to call-by-name by Ariola and Felleisen. The natural semantics for the cyclic calculus is inspired by that of Launchbury (1993) and Sestoft (1997), and we state its adequacy using a denotational semantics in the style of Launchbury; adequacy of the reduction semantics for the cyclic calculus is in turn ascribed to its correspondence with the natural semantics.

Copyright
References
Hide All
Abramsky, S. & Ong, C.-H. L. (1993) Full abstraction in the lazy lambda calculus, Inf. Comput., 105 (2): 159267.
Ariola, Z. & Felleisen, M. (1997) The call-by-need lambda calculus. J. Funct. Program., 7 (3): 265301.
Ariola, Z. M. & Blom, S. (1997) Cyclic lambda calculi. In Proc. Theoretical Aspects of Computer Software. Abadi, M. and Ito, T. (eds), Lecture Notes in Computer Science, vol. 1281. Springer, Berlin/Heidelberg, pp. 77106.
Ariola, Z. M. & Klop, J. W. (1994) Cyclic lambda graph rewriting. In Proceedings of the Symposium on Logic in Computer Science, Abramsky, S. (ed), Paris, France, pp. 416425.
Danvy, O. (2008) Defunctionalized interpreters for programming languages. In Proceedings of the International Conference on Functional Programming, Hook, James and Thiemann, Peter (eds), Victoria, BC, Canada, ACM Press.
Garcia, R., Lumsdaine, A & Sabry, A. (2009) Lazy evaluation and delimited control. In Proceedings of the ACM SIGPLAN-SIGACT Symposium on the Principles of Programming Languages, Shao, Zhong and Pierce, Benjamin C. (eds), Savannah, GA, USA. ACM Press.
Launchbury, J. (1993) A natural semantics for lazy evaluation. In Proceedings of the ACM SIGPLAN-SIGACT Symposium on the Principles of Programming Languages, Charleston, SC, USA.
Leroy, X., Doligez, D., Garrigue, J., Rémy, D. & Vouillon, J. (2008) The Objective Caml system, release 3.11 [online]. Available at: http://caml.inria.fr/ (Accessed 29 July 2009).
Maraist, J., Odersky, M. & Wadler, P. (1998) A call-by-need lambda calculus, J. Funct. Program., 8 (3): 275317.
Nakata, K. & Hasegawa, M. (2009) Small-step and big-step semantics for call-by-need (extended version). ArXiv:0907.4640v1 [cs.PL].
Okasaki, C., Lee, P. & Tarditi, D. (1994) Call-by-need and continuation-passing style, LISP Symbol. Comput., 7 (1): 5782.
Plotkin, G. (1975) Call-by-name, Call-by-value and the λ-Calculus, Theoret. Comp. Sci., 1 (2): 125159.
Sestoft, P. (1997) Deriving a lazy abstract machine, J. Funct. Program., 7 (3): 231264.
Sperber, M., Dybvig, R. K., Flatt, M. & Straaten, A. V. (2009) Revised6 Report on the Algorithmic Language Scheme. J. Funct. Program., 19 (S1): 1301.
Syme, D. (2005) Initializing mutually referential abstract objects: The value recursion challenge. In Proceedings of the Workshop on ML, Electr. Notes Theor. Comput. Sci., Tallinn, Estonia, 148 (2): 325.
Syme, D. & Margetson, J. (2008) The F# programming language [online]. Available at: http://research.microsoft.com/en-us/um/people/curtisvv/fsharp_default.aspx (Accessed 29 July 2009).
Wright, A. K. & Felleisen, M. (1994) A syntactic approach to type soundness. Information and Computation, 115 (1): 3894.
Recommend this journal

Email your librarian or administrator to recommend adding this journal to your organisation's collection.

Journal of Functional Programming
  • ISSN: 0956-7968
  • EISSN: 1469-7653
  • URL: /core/journals/journal-of-functional-programming
Please enter your name
Please enter a valid email address
Who would you like to send this to? *
×

Metrics

Altmetric attention score

Full text views

Total number of HTML views: 0
Total number of PDF views: 0 *
Loading metrics...

Abstract views

Total abstract views: 0 *
Loading metrics...

* Views captured on Cambridge Core between <date>. This data will be updated every 24 hours.

Usage data cannot currently be displayed

Small-step and big-step semantics for call-by-need

  • KEIKO NAKATA (a1) and MASAHITO HASEGAWA (a2)
Submit a response

Discussions

No Discussions have been published for this article.

×

Reply to: Submit a response


Your details


Conflicting interests

Do you have any conflicting interests? *