Skip to main content
×
×
Home

The adequacy of Launchbury's natural semantics for lazy evaluation*

  • JOACHIM BREITNER (a1)
Abstract

In his seminal paper “A Natural Semantics for Lazy Evaluation”, John Launchbury proves his semantics correct with respect to a denotational semantics, and outlines a proof of adequacy. Previous attempts to rigorize the adequacy proof, which involves an intermediate natural semantics and an intermediate resourced denotational semantics, have failed. We devised a new, direct proof that skips the intermediate natural semantics. It is the first rigorous adequacy proof of Launchbury's semantics. We have modeled our semantics in the interactive theorem prover Isabelle and machine-checked our proofs. This does not only provide a maximum level of rigor, but also serves as a tool for further work, such as a machine-checked correctness proof of a compiler transformation.

Copyright
Footnotes
Hide All
*

This work was carried out while the author was a member of the Programming Paradigms Group of the Karlsruhe Institute of Technology, Germany. The author was supported by the Deutsche Telekom Stiftung.

Footnotes
References
Hide All
Abramsky, S. (1990) The lazy lambda calculus. In Research Topics in Functional Programming. Boston, MA, USA: Addison-Wesley Longman Publishing Co., Inc., pp. 65116.
Baker-Finch, C., King, D., Hall, J. & Trinder, P. (1999) An Operational Semantics for Parallel Call-by-Need. Technical Report 99/1. Faculty of Mathematics and Computing, The Open University.
Baker-Finch, C., King, D. J. & Trinder, P. W. (2000) An operational semantics for parallel lazy evaluation. In Proceedings of ACM SIGPLAN International Conference on Functional Programming.
Ballarin, C. (2014) Locales: A module system for mathematical theories. J. Autom. Reason. 52 (2), 123153.
Breitner, J. (2013) The correctness of Launchbury's natural semantics for lazy evaluation. Archive of formal proofs, Jan. Available at: http://afp.sf.net/entries/Launchbury.html, Formal proof development.
Breitner, J. (2015a) Call arity. In TFP'14. LNCS, vol. 8843. Springer, pp. 3450.
Breitner, J. (2015b) Formally proving a compiler transformation safe. In Proceedings of Haskell Symposium. ACM.
Breitner, J. (2015c) The safety of call arity. Archive of formal proofs, Feb. Available at: http://afp.sf.net/entries/Call_Arity.shtml, Formal proof development.
Eekelen, M. van, & Mol, M. de. (2004 January) Mixed lazy/strict graph semantics. Technical Report. NIII-R0402. Radboud University Nijmegen.
Eisenberg, R. (2013) System FC, as Implemented in GHC.
Launchbury, J. (1993) A natural semantics for lazy evaluation. In Principles of Programming Languages, pp. 144–154.
Nakata, K. (2010) Denotational semantics for lazy initialization of letrec: Black holes as exceptions rather than divergence. In Proceedings of the 7th Workshop on Fixed Points in Computer Science.
Nakata, K. & Hasegawa, M. (2009) Small-step and big-step semantics for call-by-need. J. Funct. Program. 19 (6), 699722.
Sánchez-Gil, L., Hidalgo-Herrero, M. & Ortega-Mallén, Y. (2010) An operational semantics for distributed lazy evaluation. In Trends in Functional Programming, vol. 10. New York, NY, USA: Intellect Books, pp. 6580.
Sánchez-Gil, L., Hidalgo-Herrero, M. & Ortega-Mallén, Y. (2011) Relating function spaces to resourced function spaces. In Proceedings of ACM Symposium on Applied Computing, pp. 1301–1308.
Sánchez-Gil, L., Hidalgo-Herrero, M. & Ortega-Mallén, Y. (2012) A locally nameless representation for a natural semantics for lazy evaluation. In Proceedings of International Colloquium on Theoretical Aspects of Computing, pp. 1301–1308.
Sánchez-Gil, L., Hidalgo-Herrero, M. & Ortega-Mallén, Y. (2014) The role of indirections in lazy natural semantics. In Proceedings of PSI.
Sestoft, P. (1997) Deriving a lazy abstract machine. J. Funct. Program. 7 (4), 231264.
Urban, C. & Kaliszyk, C. (2012) General bindings and alpha-equivalence in nominal Isabelle. Logical Methods Comput. Sci. 8 (2). See https://lmcs.episciences.org/page/lmcs-ev for details.
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

The adequacy of Launchbury's natural semantics for lazy evaluation*

  • JOACHIM BREITNER (a1)
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? *