School of Computing

Alting Barriers: Synchronisation with Choice in Java using JCSP

Peter H. Welch, Neil C. C. Brown, James Moores, Kevin Chalmers, and Bernhard H. C. Sputh

Concurrency and Computation: Practice and Experience, 22:182-196, March 2010 The DOI should redirect to http://onlinelibrary.wiley.com.chain.kent.ac.uk/doi/10.1002/cpe.1471/abstract . [doi].

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. Download publication 152 kbytes (PDF)

Bibtex Record

@article{3068,
author = { Peter H. Welch and Neil C. C. Brown and James Moores and Kevin Chalmers and Bernhard H. C. Sputh},
title = {{A}lting {B}arriers: {S}ynchronisation with {C}hoice in {J}ava using {JCSP}},
month = {March},
year = {2010},
pages = {182-196},
keywords = {determinacy analysis, Craig interpolants},
note = { The DOI should redirect to http://onlinelibrary.wiley.com.chain.kent.ac.uk/doi/10.1002/cpe.1471/abstract  .},
doi = {10.1002/cpe.1471},
url = {http://www.cs.kent.ac.uk/pubs/2010/3068},
    publication_type = {article},
    submission_id = {5095_1289406062},
    journal = {Concurrency and Computation: Practice and Experience},
    volume = {22},
    publisher = {Wiley InterScience},
}

School of Computing, University of Kent, Canterbury, Kent, CT2 7NF

Enquiries: +44 (0)1227 824180 or contact us.

Last Updated: 21/03/2014