Computing Reviews
Today's Issue Hot Topics Search Browse Recommended My Account Log In
Review Help
Search
A data-centric approach to synchronization
Dolby J., Hammer C., Marino D., Tip F., Vaziri M., Vitek J. ACM Transactions on Programming Languages and Systems34 (1):1-48,2012.Type:Article
Date Reviewed: Jan 10 2013

Concurrency-related errors, like data races, are very difficult to track down and eliminate in large object-oriented programs. Existing approaches to prevent data races rely on protecting instruction sequences (like critical sections) with synchronization operations. Such control-centric approaches put a heavy burden on the programmer to ensure that all concurrently accessed memory locations are consistently protected. They are often error-prone and brittle.

Dolby et al. present a novel data-centric synchronization approach to handle the synchronization problem where atomic sets are defined by grouping fields of various objects. Such sets represent fields that must always be updated atomically. To preserve the consistency of an atomic set, it is associated with an appropriate consistency checker code segment. Synchronization operations are then added automatically by the compiler.

A subset of Java, called Atomic Java (AJ), is proposed here as an extension of Java with atomic sets. AJ creates annotations for data-centric concurrency control. It relies on a novel type system that produces atomic sets spanning multiple objects. AJ enables separate compilation and supports full encapsulation, ensuring efficient generation of code. Data-centric synchronization makes code easy to evaluate by refactoring classes from standard libraries and multithreaded benchmarks (SPECjbb) to use atomic sets. The process offers low annotation overhead, while successfully preventing data races.

The process requires about 40 annotations per thousand lines of code (KLOC) for the collection class and ranges from 0.6 to 11.5 per KLOC for the other applications. For all but one of the applications, the approach requires fewer annotations than the number of synchronized blocks in the original Java code. The throughput of the tuned AJ version of the SPECjbb benchmark achieves 90.8 percent of that achieved by the original Java implementation when run with 98 threads.

However, the prototype implementation has drawbacks, too. It does not support multiple atomic sets in a single class and the type system does not deal with generics. Importantly, AJ does not guarantee complete elimination of programmer errors. When a section of code manipulates data outside of the atomic set, data races or deadlocks can potentially occur.

This paper suggests an interesting system that guarantees the ability to serialize atomic sets spanning multiple objects and enables separate compilation at the same time. The low annotation overhead of this approach has been effectively demonstrated by the AJ-to-Java compiler. This makes AJ a good candidate for language-based synchronization design.

Reviewer:  Partha Pratim Das Review #: CR140819 (1304-0315)
Bookmark and Share
 
Parallel Programming (D.1.3 ... )
 
 
Data Types And Structures (D.3.3 ... )
 
 
Reliability (D.2.4 ... )
 
 
Language Constructs and Features (D.3.3 )
 
 
Software/ Program Verification (D.2.4 )
 
 
Specifying And Verifying And Reasoning About Programs (F.3.1 )
 
Would you recommend this review?
yes
no
Other reviews under "Parallel Programming": Date
How to write parallel programs: a first course
Carriero N. (ed), Gelernter D. (ed), MIT Press, Cambridge, MA, 1990. Type: Book (9780262031714)
Jul 1 1992
Parallel computer systems
Koskela R., Simmons M., ACM Press, New York, NY, 1990. Type: Book (9780201509373)
May 1 1992
Parallel functional languages and compilers
Szymanski B. (ed), ACM Press, New York, NY, 1991. Type: Book (9780201522433)
Sep 1 1993
more...

E-Mail This Printer-Friendly
Send Your Comments
Contact Us
Reproduction in whole or in part without permission is prohibited.   Copyright 1999-2024 ThinkLoud®
Terms of Use
| Privacy Policy