Disentanglement with Futures, State, and Interaction
Jatin Arora, Stefan K. Muller, Umut A. Acar
摘要
Recent work has proposed a memory property for parallel programs, called disentanglement, and showed that it is pervasive in a variety of programs, written in different languages, ranging from C/C++ to Parallel ML, and showed that it can be exploited to improve the performance of parallel functional programs. All existing work on disentanglement, however, considers the "fork/join" model for parallelism and does not apply to "futures", the more powerful approach to parallelism. This is not surprising: fork/join parallel programs exhibit a reasonably strict dependency structure (e.g., series-parallel DAGs), which disentanglement exploits. In contrast, with futures, parallel computations become first-class values of the language, and thus can be created, and passed between functions calls or stored in memory, just like other ordinary values, resulting in complex dependency structures, especially in the presence of mutable state. For example, parallel programs with futures can have deadlocks, which is impossible with fork-join parallelism.
In this paper, we are interested in the theoretical question of whether disentanglement may be extended beyond fork/join parallelism, and specifically to futures. We consider a functional language with futures, Input/Output (I/O), and mutable state (references) and show that a broad range of programs written in this language are disentangled. We start by formalizing disentanglement for futures and proving that purely functional programs written in this language are disentangled. We then generalize this result in three directions. First, we consider state (effects) and prove that stateful programs are disentangled if they are race free. Second, we show that race freedom is sufficient but not a necessary condition and non-deterministic programs, e.g. those that use atomic read-modify-operations and some non-deterministic combinators, may also be disentangled. Third, we prove that disentangled task-parallel programs written with futures are free of deadlocks, which arise due to interactions between state and the rich dependencies that can be expressed with futures. Taken together, these results show that disentanglement generalizes to parallel programs with futures and, thus, the benefits of disentanglement may go well beyond fork-join parallelism.
问问这篇 Paper
智能体会读完全文。
Lune 把这篇 Paper 索引到了每一个公式,引用它的顶会 Paper 也一样。你提问,回答直接引用原文。
引用它的顶会 Paper1
问问它们各自怎么用它它引用的顶会 Paper6
- Disentanglement in nested-parallel programsSam Westrick, Rohan Yadav, Matthew Fluet, Umut A. AcarPOPL 2020 · 被引用 19 次
- Responsive parallelism with futures and stateStefan K. Muller, Kyle Singer, Noah Goldstein, Umut A. Acar 等PLDI 2020 · 被引用 12 次
- Parallel determinacy race detection for futuresYifan Xu, Kyle Singer, I-Ting Angelina LeePPoPP 2020 · 被引用 11 次
- Provably space-efficient parallel functional programmingJatin Arora, Sam Westrick, Umut A. AcarPOPL 2021 · 被引用 9 次
- Efficient Parallel Functional Programming with EffectsJatin Arora, Sam Westrick, Umut A. AcarPLDI 2023 · 被引用 6 次
相关 Paper
- DisLog: A Separation Logic for DisentanglementAlexandre Moine, Sam Westrick, Stephanie BalzerPOPL 2024
- Language-Agnostic Static Deadlock Detection for FuturesStefan K. MullerPPoPP 2024 · 被引用 1 次
- Investigating the semantics of futures in transactional memory systemsJingna Zeng, Shady Issa, Paolo Romano, Luís E. T. Rodrigues 等PPoPP 2021 · 被引用 4 次
- Pipelines and Beyond: Graph Types for ADTs with FuturesFrancis Rinaldi, june wunder, Arthur Azevedo de Amorim, Stefan K. MullerPOPL 2024
- Modeling Reachability Types with Logical Relations: Semantic Type Soundness, Termination, Effect Safety, and Equational TheoryYuyan Bao, Songlin Jia, Guannan Wei, Oliver Bracevac 等OOPSLA 2025 · 被引用 3 次
