An Optimised Flow for Futures: From Theory to Practice
Nicolas Chappe (University of Lyon, France / EnsL, France / Claude, Bernard University Lyon 1, France / CNRS, France / Inria, France / LIP,, France), Ludovic Henrio (University of Lyon, France / EnsL, France / Claude, Bernard University Lyon 1, France / CNRS, France / Inria

TL;DR
This paper demonstrates that data-flow explicit futures are a powerful primitive for concurrent programming, enabling optimizations like the 'forward' construct, with proven equivalence and practical performance benefits.
Contribution
It proves the equivalence between 'forward' and 'return' in data-flow futures, and provides a library implementation showing practical advantages.
Findings
Data-flow explicit futures unify nested futures into plain futures.
The 'forward' construct can be optimized as a language primitive.
Benchmarks confirm the approach's performance viability.
Abstract
A future is an entity representing the result of an ongoing computation. A synchronisation with a "get" operation blocks the caller until the computation is over, to return the corresponding value. When a computation in charge of fulfilling a future delegates part of its processing to another task, mainstream languages return nested futures, and several "get" operations are needed to retrieve the computed value (we call such futures "control-flow futures"). Several approaches were proposed to tackle this issues: the "forward" construct, that allows the programmer to make delegation explicit and avoid nested futures, and "data-flow explicit futures" which natively collapse nested futures into plain futures. This paper supports the claim that data-flow explicit futures form a powerful set of language primitives, on top of which other approaches can be built. We prove the equivalence, in…
Peer Reviews
No public reviews on file for this paper yet. If you reviewed it on a platform where reviews are public (OpenReview, ICLR, NeurIPS, ICML), you can paste yours below so the community can read it here.
Videos
No videos yet. Explain this paper in a talk, walkthrough, or lecture? Add one.
