Peter Welch
Alting barriers: synchronisation with choice in Java using JCSP
Welch, Peter; Brown, Neil; Moores, James; Chalmers, Kevin; Sputh, Bernhard
Authors
Neil Brown
James Moores
Kevin Chalmers
Bernhard Sputh
Abstract
Communicating Sequential Processes for Java (JCSP) is a mature library that implements CSP-derived concurrency primitives in Java. A JCSP system is a hierarchical network of autonomous processes communicating over synchronous (optionally buffered) channels, and multiway synchronising through barriers. This paper presents a significant extension to the barrier mechanism: the fast resolution of choice between any number of barrier events, channel communications (in either direction) and timeouts. Previously, and in line with all currently released libraries and languages offering the CSP concurrency model, choice was restricted to channel inputs and timeouts. The paper demonstrates an application of alting barriers and explains the mechanisms used in their implementation that enables their use as guards in a choice. It also shows how choice over channel outputs becomes possible, as a simple consequence of having choice over barriers. Finally, an efficient implementation of CSP's broadcasting channels is presented (using a phased barrier synchronisation pattern) and a mechanism for allowing choice over these is discussed. With this extended JCSP, almost all CSP-specified systems can now be directly implemented. The new library is available under LGPL open source
Citation
Welch, P., Brown, N., Moores, J., Chalmers, K., & Sputh, B. (2010). Alting barriers: synchronisation with choice in Java using JCSP. Concurrency and Computation: Practice and Experience, 22(8), 1049-1062. https://doi.org/10.1002/cpe.1471
Journal Article Type | Article |
---|---|
Online Publication Date | Mar 1, 2010 |
Publication Date | Jun 10, 2010 |
Deposit Date | Aug 31, 2010 |
Print ISSN | 1532-0626 |
Publisher | Wiley |
Peer Reviewed | Peer Reviewed |
Volume | 22 |
Issue | 8 |
Pages | 1049-1062 |
DOI | https://doi.org/10.1002/cpe.1471 |
Keywords | Theoretical Computer Science; Computer Networks and Communications; Computational Theory and Mathematics; Software; Computer Science Applications |
Public URL | http://researchrepository.napier.ac.uk/id/eprint/3822 |
Publisher URL | http://dx.doi.org/10.1002/cpe.1471 |
You might also like
Groovy Parallel Patterns: A Library to Support Parallelization
(2016)
Presentation / Conference
Simulating Dynamic Vehicle Routing Problems with Athos
(2019)
Conference Proceeding
Athos - A Model Driven Approach to Describe and Solve Optimisation Problems
(2019)
Conference Proceeding
Building a C++CSP Channel Using C++ Atomics
(2017)
Conference Proceeding