Hostname: page-component-89b8bd64d-46n74 Total loading time: 0 Render date: 2026-05-13T05:14:14.515Z Has data issue: false hasContentIssue false

Back to futures

Published online by Cambridge University Press:  28 February 2022

KLAAS PRUIKSMA
Affiliation:
Computer Science Department Carnegie Mellon University, Pittsburgh, PA 15213, USA (e-mail: kpruiksm@andrew.cmu.edu)
FRANK PFENNING
Affiliation:
Computer Science Department Carnegie Mellon University, Pittsburgh, PA 15213, USA (e-mail: fp@cs.cmu.edu)
Rights & Permissions [Opens in a new window]

Abstract

Common approaches to concurrent programming begin with languages whose semantics are naturally sequential and add new constructs that provide limited access to concurrency, as exemplified by futures. This approach has been quite successful, but often does not provide a satisfactory theoretical backing for the concurrency constructs, and it can be difficult to give a good semantics that allows a programmer to use more than one of these constructs at a time. We take a different approach, starting with a concurrent language based on a Curry–Howard interpretation of adjoint logic, to which we add three atomic primitives that allow us to encode sequential composition and various forms of synchronization. The resulting language is highly expressive, allowing us to encode futures, fork/join parallelism, and monadic concurrency in the same framework. Notably, since our language is based on adjoint logic, we are able to give a formal account of linear futures, which have been used in complexity analysis by Blelloch and Reid-Miller. The uniformity of this approach means that we can similarly work with many of the other concurrency primitives in a linear fashion, and that we can mix several of these forms of concurrency in the same program to serve different purposes.

Information

Type
Research Article
Creative Commons
Creative Common License - CCCreative Common License - BY
This is an Open Access article, distributed under the terms of the Creative Commons Attribution licence (https://creativecommons.org/licenses/by/4.0/), which permits unrestricted re-use, distribution, and reproduction in any medium, provided the original work is properly cited.
Copyright
© The Author(s), 2022. Published by Cambridge University Press
Figure 0

Fig. 1: Logical rules ($\alpha \in \{0,1\}$ with $\alpha = 1$ permitted only if $C \in \sigma(m)$).

Figure 1

Fig. 2: Types and process expressions.

Figure 2

Fig. 3: Typing rules ($\alpha \in \{0,1\}$ with $\alpha = 1$ permitted only if $C \in \sigma(m)$).

Figure 3

Fig. 4: Concurrent dynamic rules(All addresses with distinct names [e.g. $c_m$ and $d_m$] are different).

Submit a response

Discussions

No Discussions have been published for this article.