Strictly capturing non-strict closures
Strictly capturing non-strict closures
复制标题
严格捕获非严格闭包
DOI:
10.1145/3441296.3441398
复制
发表时间:
2021
期刊:
影响因子:
--
通讯作者:
Ariola, Zena M.
中科院分区:
文献类型:
--
作者:
Sullivan, Zachary J.;Downen, Paul;Ariola, Zena M.
All functional languages need closures. Closure-conversion is a compiler transformation that embeds static code into the program for creating and manipulating closures, avoiding the need for special run-time closure support. For call-by-value languages, closure-conversion has been the focus of extensive studies concerning correctness, such as type preservation and contextual equivalence, and performance, such as space usage. Unfortunately, non-strict languages have been neglected in these studies. This paper aims to fill this gap.We begin with both a call-by-name and a call-by-need source language whose semantics automatically generates closures at run-time. Next, we give type-preserving closure-conversions for these two non-strict languages into a lower-level target languagewithoutautomatic closure generation at run-time. Despite the fact that our source languages are non-strict, we show that closures must be created eagerly, which requires a strict notion of product in the target language. We extend logical relation techniques used to prove compiler correctness for call-by-value languages, to apply to non-strict languages too. In doing so, we identify some important properties for reasoning about memoization with a heap.
登录
查看更多内容
DOI:
--
发表时间:
2004
期刊:
影响因子:
--
作者:
Thomas Johnsson;T. S. Badhusgatan
通讯作者:
T. S. Badhusgatan
DOI:
--
发表时间:
2018
期刊:
Foundations of Software Science and Computation Structure
影响因子:
--
作者:
Étienne Miquey;Hugo Herbelin
通讯作者:
Hugo Herbelin
DOI:
--
发表时间:
2018
期刊:
ACM-SIGPLAN Symposium on Programming Language Design and Implementation
影响因子:
--
作者:
W. J. Bowman;Amal J. Ahmed
通讯作者:
Amal J. Ahmed
DOI:
--
发表时间:
2019
期刊:
Proc. ACM Program. Lang.
影响因子:
--
作者:
Zoe Paraskevopoulou;A. Appel
通讯作者:
A. Appel
DOI:
10.1145/75277.75303
发表时间:
1989
期刊:
Proceedings Design, Automation and Test in Europe. Conference and Exhibition 2001
影响因子:
--
作者:
A. Appel;T. Jim
通讯作者:
T. Jim