Skip to main content Accessibility help
×
Home
Hostname: page-component-768ffcd9cc-5sfl8 Total loading time: 0.2 Render date: 2022-12-05T19:13:50.519Z Has data issue: true Feature Flags: { "useRatesEcommerce": false } hasContentIssue true

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

Published online by Cambridge University Press:  03 January 2018

JOACHIM BREITNER*
Affiliation:
Computer and Information Science, University of Pennsylvania, Philadelphia, PA-19146, USA (e-mail: joachim@cis.upenn.edu)
Rights & Permissions[Opens in a new window]

Abstract

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

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.

Type
Articles
Copyright
Copyright © Cambridge University Press 2018 

Footnotes

*

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.

References

Abramsky, S. (1990) The lazy lambda calculus. In Research Topics in Functional Programming. Boston, MA, USA: Addison-Wesley Longman Publishing Co., Inc., pp. 65116.Google Scholar
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.Google Scholar
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.Google Scholar
Ballarin, C. (2014) Locales: A module system for mathematical theories. J. Autom. Reason. 52 (2), 123153.CrossRefGoogle Scholar
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.Google Scholar
Breitner, J. (2015a) Call arity. In TFP'14. LNCS, vol. 8843. Springer, pp. 3450.Google Scholar
Breitner, J. (2015b) Formally proving a compiler transformation safe. In Proceedings of Haskell Symposium. ACM.Google Scholar
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.Google Scholar
Eekelen, M. van, & Mol, M. de. (2004 January) Mixed lazy/strict graph semantics. Technical Report. NIII-R0402. Radboud University Nijmegen.Google Scholar
Eisenberg, R. (2013) System FC, as Implemented in GHC.Google Scholar
Launchbury, J. (1993) A natural semantics for lazy evaluation. In Principles of Programming Languages, pp. 144–154.Google Scholar
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.Google Scholar
Nakata, K. & Hasegawa, M. (2009) Small-step and big-step semantics for call-by-need. J. Funct. Program. 19 (6), 699722.CrossRefGoogle Scholar
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.Google Scholar
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.CrossRefGoogle Scholar
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.CrossRefGoogle Scholar
Sánchez-Gil, L., Hidalgo-Herrero, M. & Ortega-Mallén, Y. (2014) The role of indirections in lazy natural semantics. In Proceedings of PSI.Google Scholar
Sestoft, P. (1997) Deriving a lazy abstract machine. J. Funct. Program. 7 (4), 231264.CrossRefGoogle Scholar
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.CrossRefGoogle Scholar
Submit a response

Discussions

No Discussions have been published for this article.
You have Access
2
Cited by

Save article to Kindle

To save this article to your Kindle, first ensure coreplatform@cambridge.org is added to your Approved Personal Document E-mail List under your Personal Document Settings on the Manage Your Content and Devices page of your Amazon account. Then enter the ‘name’ part of your Kindle email address below. Find out more about saving to your Kindle.

Note you can select to save to either the @free.kindle.com or @kindle.com variations. ‘@free.kindle.com’ emails are free but can only be saved to your device when it is connected to wi-fi. ‘@kindle.com’ emails can be delivered even when you are not connected to wi-fi, but note that service fees apply.

Find out more about the Kindle Personal Document Service.

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

Save article to Dropbox

To save this article to your Dropbox account, please select one or more formats and confirm that you agree to abide by our usage policies. If this is the first time you used this feature, you will be asked to authorise Cambridge Core to connect with your Dropbox account. Find out more about saving content to Dropbox.

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

Save article to Google Drive

To save this article to your Google Drive account, please select one or more formats and confirm that you agree to abide by our usage policies. If this is the first time you used this feature, you will be asked to authorise Cambridge Core to connect with your Google Drive account. Find out more about saving content to Google Drive.

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

Reply to: Submit a response

Please enter your response.

Your details

Please enter a valid email address.

Conflicting interests

Do you have any conflicting interests? *