## A call-by-need lambda-calculus with locally bottom-avoiding choice: Context lemma and correctness of transformations (2008)

### Cached

### Download Links

Venue: | MATHEMATICAL STRUCTURES IN COMPUTER SCIENCE |

Citations: | 15 - 10 self |

### BibTeX

@ARTICLE{Sabel08acall-by-need,

author = {David Sabel and Manfred Schmidt-schauß},

title = {A call-by-need lambda-calculus with locally bottom-avoiding choice: Context lemma and correctness of transformations},

journal = {MATHEMATICAL STRUCTURES IN COMPUTER SCIENCE},

year = {2008},

volume = {18},

number = {3},

pages = {501--553}

}

### OpenURL

### Abstract

We present a higher-order call-by-need lambda calculus enriched with constructors, case-expressions, recursive letrec-expressions, a seq-operator for sequential evaluation and a non-deterministic operator amb that is locally bottom-avoiding. We use a small-step operational semantics in form of a single-step rewriting system that defines a (nondeterministic) normal order reduction. This strategy can be made fair by adding resources for bookkeeping. As equational theory we use contextual equivalence, i.e. terms are equal if plugged into any program context their termination behaviour is the same, where we use a combination of may- as well as must-convergence, which is appropriate for non-deterministic computations. We show that we can drop the fairness condition for equational reasoning, since the valid equations w.r.t. normal order reduction are the same as for fair normal order reduction. We evolve different proof tools for proving correctness of program transformations, in particular, a context lemma for may- as well as mustconvergence is proved, which restricts the number of contexts that need to be examined for proving contextual equivalence. In combination with so-called complete sets of commuting and forking diagrams we show that all the deterministic reduction rules and also some additional transformations preserve contextual equivalence.We also prove a standardisation theorem for fair normal order reduction. The structure of the ordering <= c is also analysed: Ω is not a least element, and <=c already implies contextual equivalence w.r.t. may-convergence.