Language Constructs for Safe Parallel Programming on Multi-Cores
2016 (English)Doctoral thesis, comprehensive summary (Other academic)
The last decade has seen the transition from single-core processors to multi-cores and many-cores. This move has by and large shifted the responsibility from chip manufacturers to programmers to keep up with ever-increasing expectations on performance. In the single-core era, improvements in hardware capacity could immediately be leveraged by an application: faster machine - faster program. In the age of the multi-cores, this is no longer the case. Programs must be written in specific ways to utilize available parallel hardware resources.
Programming language support for concurrent and parallel programming is poor in most popular object-oriented programming languages. Shared memory, threads and locks is the most common concurrency model provided. Threads and locks are hard to understand, error-prone and inflexible; they break encapsulation - the very foundation of the object-oriented approach. This makes it hard to break large complex problems into smaller pieces which can be solved independently and composed to make a whole. Ubiquitous parallelism and object-orientation, seemingly, do not match.
Actors, or active objects, have been proposed as a concurrency model better fit for object-oriented programming than threads and locks. Asynchronous message passing between actors each with a logical thread of control preserves encapsulation as objects themselves decide when messages are executed. Unfortunately most implementations of active objects do not prevent sharing of mutable objects across actors. Sharing, whether on purpose or by accident, exposes objects to multiple threads of control, destroying object encapsulation.
In this thesis we show techniques for compiler-enforced isolation of active objects, while allowing sharing and zero-copy communication of mutable data in the cases where it is safe to do so. We also show how the same techniques that enforce isolation can be utilized internal to an active object to allow data race-free parallel message processing and data race-free structured parallel computations. This overcomes the coarse-grained nature of active object parallelism without compromising safety.
Place, publisher, year, edition, pages
Uppsala: Acta Universitatis Upsaliensis, 2016. , 105 p.
Digital Comprehensive Summaries of Uppsala Dissertations from the Faculty of Science and Technology, ISSN 1651-6214 ; 1319
Programming Languages, Type Systems, Ownership Types, Concurrency, Parallelism, Actors, Active Objects, Structured Parallelism, Data Race-Freedom, Immutability, Uniqueness
Research subject Computer Science
IdentifiersURN: urn:nbn:se:uu:diva-266795ISBN: 978-91-554-9413-1OAI: oai:DiVA.org:uu-266795DiVA: diva2:872118
2016-01-18, 2446, ITC, Lägerhyddsvägen 2, hus 2, Uppsala, 13:00 (English)
Henrio, Ludovic, CR1
Wrigstad, Tobias, Docent
List of papers