English

A Model of Cooperative Threads

Programming Languages 2015-07-01 v2

Abstract

We develop a model of concurrent imperative programming with threads. We focus on a small imperative language with cooperative threads which execute without interruption until they terminate or explicitly yield control. We define and study a trace-based denotational semantics for this language; this semantics is fully abstract but mathematically elementary. We also give an equational theory for the computational effects that underlie the language, including thread spawning. We then analyze threads in terms of the free algebra monad for this theory.

Keywords

Cite

@article{arxiv.1009.2405,
  title  = {A Model of Cooperative Threads},
  author = {Martín Abadi and Gordon D. Plotkin},
  journal= {arXiv preprint arXiv:1009.2405},
  year   = {2015}
}

Comments

39 pages, 5 figures

R2 v1 2026-06-21T16:13:10.846Z