Results 1  10
of
10
Reasoning about Programs in ContinuationPassing Style
 Lisp and Symbolic Computation
"... Plotkin's v calculus for callbyvalue programs is weaker than the fij calculus for the same programs in continuationpassing style (CPS). To identify the callby value axioms that correspond to fij on CPS terms, we define a new CPS transformation and an inverse mapping, both of which are in ..."
Abstract

Cited by 161 (13 self)
 Add to MetaCart
Plotkin's v calculus for callbyvalue programs is weaker than the fij calculus for the same programs in continuationpassing style (CPS). To identify the callby value axioms that correspond to fij on CPS terms, we define a new CPS transformation and an inverse mapping, both of which are interesting in their own right. Using the new CPS transformation, we determine the precise language of CPS terms closed under fijtransformations, as well as the callbyvalue axioms that correspond to the socalled administrative fijreductions on CPS terms. Using the inverse mapping, we map the remaining fi and j equalities on CPS terms to axioms on callbyvalue terms. On the pure (constant free) set ofterms, the resulting set of axioms is equivalent to Moggi's computational calculus. If the callbyvalue language includes the control operators abort and callwithcurrentcontinuation, the axioms are equivalent to an extension of Felleisen et al.'s vCcalculus and to the equational subtheory of Talcott's logic IOCC. Contents 1 Compiling with and without Continuations 4 2 : Calculi and Semantics 7 3 The Origins and Practice of CPS 10 3.1 The Original Encoding : : : : : : : : : : : : : : : : : : : : : 10 3.2 The Universe of CPS Terms : : : : : : : : : : : : : : : : : : 11 4 A Compacting CPS Transformation 13
The Formal Relationship Between Direct and ContinuationPassing Style Optimizing Compilers: A Synthesis of Two Paradigms
, 1994
"... Compilers for higherorder programming languages like Scheme, ML, and Lisp can be broadly characterized as either "direct compilers" or "continuationpassing style (CPS) compilers", depending on their main intermediate representation. Our central result is a precise correspondenc ..."
Abstract

Cited by 15 (0 self)
 Add to MetaCart
Compilers for higherorder programming languages like Scheme, ML, and Lisp can be broadly characterized as either "direct compilers" or "continuationpassing style (CPS) compilers", depending on their main intermediate representation. Our central result is a precise correspondence between the two compilation strategies. Starting from
On Interderiving Smallstep and Bigstep Semantics: A Case Study for Storeless Callbyneed Evaluation
"... Starting from the standard callbyneed reduction for the λcalculus that is common to Ariola, Felleisen, Maraist, Odersky, and Wadler, we interderive a series of hygienic semantic artifacts: a reductionfree storeless abstract machine, a continuationpassing evaluation function, and what appears t ..."
Abstract
 Add to MetaCart
Starting from the standard callbyneed reduction for the λcalculus that is common to Ariola, Felleisen, Maraist, Odersky, and Wadler, we interderive a series of hygienic semantic artifacts: a reductionfree storeless abstract machine, a continuationpassing evaluation function, and what appears to be the first heapless natural semantics for callbyneed evaluation. Furthermore we observe that the evaluation function implementing this natural semantics is in defunctionalized form. The refunctionalized counterpart of this evaluation function implements an extended direct semantics in the sense of Cartwright and Felleisen. Overall, the semantic artifacts presented here are simpler than many other such artifacts that have been independently worked out, and which require ingenuity, skill, and independent soundness proofs on a casebycase basis. They are also simpler to interderive because the interderivational tools (e.g., refocusing and defunctionalization) already exist. List of Figures 1 Recomposition of outsidein contexts..................... 11 2 Recomposition of insideout contexts..................... 11 3 Decomposition of an answer term into itself and of a nonanswer term into a potential redex and its evaluation context 12 4 Reductionbased refocusing.......................... 17 5 Reductionfree refocusing........................... 17 6 Storeless abstract machine for callbyneed evaluation........... 18 7 The storeless abstract machine of Figure 6 after transition compression.. 20 8 Heapless natural semantics for callbyneed evaluation........... 23
unknown title
"... Delimited control operators abound, but their relationships are illunderstood, and it remains unclear which (if any) to consider canonical. Although all delimited control operators ever proposed can be implemented using undelimited continuations and mutable state, Gasbichler and Sperber [28] showed ..."
Abstract
 Add to MetaCart
Delimited control operators abound, but their relationships are illunderstood, and it remains unclear which (if any) to consider canonical. Although all delimited control operators ever proposed can be implemented using undelimited continuations and mutable state, Gasbichler and Sperber [28] showed that an implementation that does not rely on undelimited continuations can be much more efficient. Unfortunately, they only implemented Felleisen’s control
Abstract Analyzing the Environment Structure of HigherOrder Languages using Frame Strings
"... Reasoning about program behaviour in programming languages based on the λ calculus requires reasoning in a unified way about control, data and environment structure. Previous analysis work has done an inadequate job on the environment component of this task. We develop a new analytic framework, ∆CFA ..."
Abstract
 Add to MetaCart
Reasoning about program behaviour in programming languages based on the λ calculus requires reasoning in a unified way about control, data and environment structure. Previous analysis work has done an inadequate job on the environment component of this task. We develop a new analytic framework, ∆CFA, which is based on a new abstraction: frame strings, an enriched variant of procedure strings that can be used to model both control flow and environment allocation. This abstraction enables new environmentsensitive analyses and transformations that have not been previously attainable. We state the critical theorems needed to establish correctness of the entire technology suite, with their proofs. Key words: lambda calculus, program analysis, superbeta, higherorder functional languages, DeltaCFA, controlflow analysis, dataflow analysis, frame strings, continuationpassing style, CPS, abstract interpretation Preface: On Reynolds and the spectre of buggy optimisers In February 1989, one of us—Shivers—assembled a thesis committee for his nascent dissertation on the controlflow analysis of higherorder languages. At the thesis proposal, John Reynolds was the committee member who registered a strong desire to see proofs of the techniques to be developed. His precise words to this effect were: “After all, you wouldn’t want a Ph.D. for a buggy optimiser, would you?” The candidate so being questioned expressed what he hoped was a suitable level
unknown title
"... From shift and reset to polarized linear logic Griffin [22] pointed out that, just as the pure λcalculus corresponds to intuitionistic logic, a λcalculus with firstclass continuations corresponds to classical logic. We study how firstclass delimited continuations [13], in the form of Danvy and Fi ..."
Abstract
 Add to MetaCart
From shift and reset to polarized linear logic Griffin [22] pointed out that, just as the pure λcalculus corresponds to intuitionistic logic, a λcalculus with firstclass continuations corresponds to classical logic. We study how firstclass delimited continuations [13], in the form of Danvy and Filinski’s shift and reset operators [10, 11], can also be logically interpreted. First, we refine Danvy and Filinski’s type system for shift and reset to distinguish between pure and impure functions. This refinement not only paves the way for answer type polymorphism, which makes more terms typable, but also helps us invert the continuationpassingstyle (CPS) transform: any pure λterm with an appropriate type is βηequivalent to the CPS transform of some shiftreset expression. We conclude that the λcalculus with shift and reset and the pure λcalculus have the same logical interpretation, namely good old intuitionistic logic. Second, we mix delimited continuations with undelimited ones. Informed by the preceding conclusion, we translate the λcalculus with shift and reset into a polarized variant of linear logic [34] that integrates classical and intuitionistic reasoning. Extending previous work on the λµcalculus [36, 37, 40], this unifying intermediate language expresses computations with and without control effects, on delimited and undelimited continuations, in callbyvalue and callbyname settings. 1
unknown title
"... Analyzing the environment structure of higherorder languages using frame strings ..."
Abstract
 Add to MetaCart
Analyzing the environment structure of higherorder languages using frame strings
HigherOrder and Symbolic Computation manuscript No.
"... (will be inserted by the editor) A static simulation of dynamic delimited control Chungchieh Shan the date of receipt and acceptance should be inserted later Abstract We present a continuationpassingstyle (CPS) transformation for some dynamic delimitedcontrol operators, including Felleisen’s con ..."
Abstract
 Add to MetaCart
(will be inserted by the editor) A static simulation of dynamic delimited control Chungchieh Shan the date of receipt and acceptance should be inserted later Abstract We present a continuationpassingstyle (CPS) transformation for some dynamic delimitedcontrol operators, including Felleisen’s control and prompt, that extends a standard callbyvalue CPS transformation. Based on this new transformation, we show how Danvy and Filinski’s static delimitedcontrol operators shift and reset simulate dynamic operators, allaying in passing some skepticism in the literature about the existence of such a simulation. The new CPS transformation and simulation use recursive delimited continuations to avoid undelimited control and the overhead it incurs in implementation and reasoning. Keywords delimited control operators; macro expressibility; continuationpassing style (CPS); shift and reset; control and prompt 1