Responsive parallelism with futures and state

Stefan K. Muller, Kyle Singer, Noah Goldstein, Umut A. Acar, Kunal Agrawal, I. Ting Angelina Lee

Research output: Chapter in Book/Report/Conference proceedingConference contributionpeer-review

11 Scopus citations

Abstract

Motivated by the increasing shift to multicore computers, recent work has developed language support for responsive parallel applications that mix compute-intensive tasks with latency-sensitive, usually interactive, tasks. These developments include calculi that allow assigning priorities to threads, type systems that can rule out priority inversions, and accompanying cost models for predicting responsiveness. These advances share one important limitation: all of this work assumes purely functional programming. This is a significant restriction, because many realistic interactive applications, from games to robots to web servers, use mutable state, e.g., for communication between threads. In this paper, we lift the restriction concerning the use of state. We present λi4, a calculus with implicit parallelism in the form of prioritized futures and mutable state in the form of references. Because both futures and references are first-class values, λi4 programs can exhibit complex dependencies, including interaction between threads and with the external world (users, network, etc). To reason about the responsiveness of λi4 programs, we extend traditional graph-based cost models for parallelism to account for dependencies created via mutable state, and we present a type system to outlaw priority inversions that can lead to unbounded blocking. We show that these techniques are practical by implementing them in C++ and present an empirical evaluation.

Original languageEnglish
Title of host publicationPLDI 2020 - Proceedings of the 41st ACM SIGPLAN Conference on Programming Language Design and Implementation
EditorsAlastair F. Donaldson, Emina Torlak
PublisherAssociation for Computing Machinery
Pages577-591
Number of pages15
ISBN (Electronic)9781450376136
DOIs
StatePublished - Jun 11 2020
Event41st ACM SIGPLAN Conference on Programming Language Design and Implementation, PLDI 2020 - London, United Kingdom
Duration: Jun 15 2020Jun 20 2020

Publication series

NameProceedings of the ACM SIGPLAN Conference on Programming Language Design and Implementation (PLDI)

Conference

Conference41st ACM SIGPLAN Conference on Programming Language Design and Implementation, PLDI 2020
Country/TerritoryUnited Kingdom
CityLondon
Period06/15/2006/20/20

Keywords

  • Cilk
  • Concurrency
  • Futures
  • Parallelism
  • Responsiveness
  • Shared memory
  • Type systems

Fingerprint

Dive into the research topics of 'Responsive parallelism with futures and state'. Together they form a unique fingerprint.

Cite this