## Relational semantics for higher-order programs (2006)

### Cached

### Download Links

- [kamal.aboulhosn.org]
- [www.cs.cornell.edu]
- DBLP

### Other Repositories/Bibliography

Venue: | Proc. 8th Int. Conf. Mathematics of Program Construction (MPC’06 |

Citations: | 3 - 2 self |

### BibTeX

@INPROCEEDINGS{Aboul-hosn06relationalsemantics,

author = {Kamal Aboul-hosn and Dexter Kozen},

title = {Relational semantics for higher-order programs},

booktitle = {Proc. 8th Int. Conf. Mathematics of Program Construction (MPC’06},

year = {2006},

pages = {29--48},

publisher = {Springer}

}

### OpenURL

### Abstract

Abstract. Most previous work on the semantics of higher-order programs with local state involves complex storage modeling with pointers and memory cells, complicated categorical constructions, or reasoning in the presence of context. In this paper we show how a relatively simple relational semantics can be used to avoid these complications. We provide a natural relational semantics for a programming language with higher-order functions. The semantics is purely compositional, with all contextual considerations completely encapsulated in the state. We show several equivalence proofs using this semantics based on examples of Meyer and Sieber (1988). 1

### Citations

937 | A Theory of Objects - Abadi, Cardelli - 1996 |

899 | Dynamic Logic [M
- Harel, Kozen, et al.
- 2000
(Show Context)
Citation Context ...e nominally functional. Our semantics allows destructive updates, but no aliasing. Fully compositional relational semantics have been quite popular for firstorder imperative programs (see for example =-=[26]-=- and references therein), but to our knowledge this is the first attempt to provide semantics in this style to higher-order programs. We are ultimately interested in moving toward a more axiomatic tre... |

500 |
Denotational Semantics: The Scott-Strachey Approach to Programming Language Semantics
- Stoy
- 1977
(Show Context)
Citation Context ...; x) λz.(y := y + z ; x := y)] = {(θ, rest(η), b) | ∃ρ ∃τ η = rest(τ), b = rest(τ)(x), ρ = (f = (λz.(y := y + z ; x := y), actv(θ))) + θ, ((z = 1 : actv(θ)) + ρ, τ) ∈ [y := y + z ; x := y ]}. (4) (5) =-=(6)-=-sUsing 3.7(i) and (iv), [y := y + z ] = {(σ, σ[y/σ(y) + σ(z)]) | σ(y), σ(z) exist} [x := y ] = {(σ, σ[x/σ(y)]) | σ(x), σ(y) exist} [y := y + z ; x := y ] = [y := y + z ] ◦ [x := y ] = {(σ, σ[y/σ(y) + ... |

155 | Abstract syntax and variable binding - Fiore, Plotkin, et al. - 1999 |

123 | A fully abstract game semantics for general references - Abramsky, Honda, et al. - 1998 |

121 | On the observable properties of higher order functions that dynamically create local names (preliminary report - Pitts, Stark - 1993 |

119 | The complexity of Kleene algebra with tests
- Cohen, Kozen, et al.
- 1996
(Show Context)
Citation Context ...are ultimately interested in moving toward a more axiomatic treatment of program equivalence and partial correctness for higher-order programs in the style of Hoare logic or Kleene algebra with tests =-=[27]-=-. Our compositional program operators are based on the Kleene algebra operators (see [27, 26]), which have well-understood relational models and are simpler and more amenable to axiomatic treatment th... |

116 | Operational reasoning for functions with local state - Pitts, Stark - 1998 |

113 | Equivalence in functional languages with effects - Mason, Talcott - 1991 |

104 | Linearity, sharing and state: a fully abstract game semantics for Idealized Algol with active expressions - Abramsky, McCusker - 1997 |

99 |
Towards fully abstract semantics for local variables: preliminary report
- Meyer, Sieber
(Show Context)
Citation Context ...e, although this notion makes the most sense in a purely functional context (see for example [2, 3]). Work in modeling local state dates back over thirty years. Early seminal work by Meyer and Sieber =-=[12]-=- used the store model of Halpern-Meyer-Trakhtenbrot to prove equivalence of ALGOL procedures with no parameters. Their goal was to formalize informal arguments about the contextual equivalence of prog... |

87 |
A Theory of Programming Language Semantics
- MILNE, STRACHEY
- 1976
(Show Context)
Citation Context ...y = 4 f = λz.(y := y + z ; x := y) in f(1) ; x end where x, y, z, and f are all distinct variables. Translating this program into a λ-expression, we obtain λy.(λf.(f(1) ; x) λz.(y := y + z ; x := y)) =-=(4)-=-. First we give an operational account of the computation. Suppose the input state is σ with active environment α. The expression is an application of a function of type int → int, thus 3.6(iv) applie... |

75 | Operationally-based theories of program equivalence - Pitts - 1997 |

65 | Call-by-value games - Abramsky, McCusker - 1997 |

46 |
A category-theoretic approach to the semantics of programming languages
- Oles
- 1982
(Show Context)
Citation Context ...y) end], we expand the definition and simplify. Prepending the binding y = c to actv(σ) and evaluating Q(x) in that environment, we would get (say) ((z = b : β) + (y = c) + σ, ρ, (λw.p, γ)) ∈ [q; e], =-=(10)-=- and we wish to apply (λw.p, γ) to y in the active environment of rest(ρ). The corresponding calculation for [Q(x)(c)] starts in state (z = b : β) + σ. But there is an embedding of this state in (z = ... |

42 | Categorical models for local names
- Stark
- 1996
(Show Context)
Citation Context ...ve [let x = c in P () end] = [λx.P () c] Similarly, from 3.7(vii) and 3.6(i), we have = {(σ, rest(τ)) | ((x = c) + σ, τ) ∈ [P ()]}. (7) [P ()] = {(σ, rest(τ)) | σ(P ) = (λ().p, β), (β + σ, τ) ∈ [p ]} =-=(8)-=- ∪ {(σ, σ) | σ(P ) exists and is an intrinsic value}. Substituting (8) in (7) and simplifying, we obtain [let x = c in P () end] = {(σ, rest(rest(η))) | σ(P ) = (λ().p, β), (β + (x = c) + σ, η) ∈ [p ]... |

40 | Observable sequentiality and full abstraction
- CARTWRIGHT, FELLEISEN
- 1991
(Show Context)
Citation Context ...l is to design a semantics that is fully abstract, where observable equivalence implies semantic equivalence, although this notion makes the most sense in a purely functional context (see for example =-=[2, 3]-=-). Work in modeling local state dates back over thirty years. Early seminal work by Meyer and Sieber [12] used the store model of Halpern-Meyer-Trakhtenbrot to prove equivalence of ALGOL procedures wi... |

36 | Operational semantics and program equivalence
- Pitts
- 2002
(Show Context)
Citation Context ...cally involves the notion of contextual or observable equivalence, where two programs are considered equivalent if either can be put in the context of a larger program and yield the same value. Pitts =-=[1]-=- explains that these notions are difficult to define formally, because there is no clear agreement on the meaning of program context and observable behavior. A common goal is to design a semantics tha... |

36 | Semantics of local variables
- O’Hearn, Tennent
- 1992
(Show Context)
Citation Context ... a set of storage locations [4–7]. The inability to prove some simple programsequivalences using traditional denotational techniques led several researchers to take a categorical approach [8–10]. See =-=[11]-=- for more information regarding the history of these approaches. More recently, several researchers have investigated the use of operational semantics to reason about ML programs with references. Whil... |

30 | References, local variables and operational reasoning - Mason, Talcott |

26 |
The semantics of local storage, or What makes the free list free
- Halpern, Meyer, et al.
- 1983
(Show Context)
Citation Context ... end P ().sProof. From 3.6(iii) and (iv), after simplification we have [let x = c in P () end] = [λx.P () c] Similarly, from 3.7(vii) and 3.6(i), we have = {(σ, rest(τ)) | ((x = c) + σ, τ) ∈ [P ()]}. =-=(7)-=- [P ()] = {(σ, rest(τ)) | σ(P ) = (λ().p, β), (β + σ, τ) ∈ [p ]} (8) ∪ {(σ, σ) | σ(P ) exists and is an intrinsic value}. Substituting (8) in (7) and simplifying, we obtain [let x = c in P () end] = {... |

19 | A game semantics of local names and good variables - Laird - 2004 |

19 | Isolating side effects in sequential languages - Riecke, Viswanathan - 1995 |

13 | A relational account of call-by-value sequentiality - Riecke, Sandholm - 1997 |

8 | Full abstraction, totality and PCF
- Plotkin
- 1999
(Show Context)
Citation Context ...l is to design a semantics that is fully abstract, where observable equivalence implies semantic equivalence, although this notion makes the most sense in a purely functional context (see for example =-=[2, 3]-=-). Work in modeling local state dates back over thirty years. Early seminal work by Meyer and Sieber [12] used the store model of Halpern-Meyer-Trakhtenbrot to prove equivalence of ALGOL procedures wi... |

6 |
Mathematical concepts in programmng language semantics
- Scott
- 1972
(Show Context)
Citation Context ...f(1)]◦ [x] = {(σ, rest(τ), rest(τ)(x)) | ∃(λx.p, β) σ(f) = (λx.p, β), ((x = 1 : β) + σ, τ) ∈ [p ], rest(τ)(x) exists} ∪ {(σ, σ, σ(x)) | σ(f) exists and is intrinsic, σ(x) exists}. Combining this with =-=(5)-=- and simplifying yields [λf.(f(1) ; x) λz.(y := y + z ; x := y)] = {(θ, rest(η), b) | ∃ρ ∃τ η = rest(τ), b = rest(τ)(x), ρ = (f = (λz.(y := y + z ; x := y), actv(θ))) + θ, ((z = 1 : actv(θ)) + ρ, τ) ∈... |

5 | Axiomatizing operational equivalence in the presence of effects - Mason, Talcott - 1989 |

3 |
The essence of ALGOL
- Reyonlds
- 1981
(Show Context)
Citation Context ... {(σ, σ) | σ(P ) exists and is an intrinsic value}. Substituting (8) in (7) and simplifying, we obtain [let x = c in P () end] = {(σ, rest(rest(η))) | σ(P ) = (λ().p, β), (β + (x = c) + σ, η) ∈ [p ]} =-=(9)-=- ∪ {(σ, σ) | σ(P ) exists and is an intrinsic value}. To show (8) and (9) are equal, it suffices to show that for all ρ, the following two statements are equivalent: ∃η ρ = rest(rest(η)), (β + (x = c)... |