Abstract
In this paper, we consider concurrent programs in which the shared state consists of instances of linearizable ADTs (abstract data types). We present an automated approach to concurrency control that addresses a common need: the need to atomically execute a code fragment, which may contain multiple ADT operations on multiple ADT instances. We present a synthesis algorithm that automatically enforces atomicity of given code fragments (in a client program) by inserting pessimistic synchronization that guarantees atomicity and deadlock-freedom (without using any rollback mechanism). Our algorithm takes a commutativity specification as an extra input. This specification indicates for every pair of ADT operations the conditions under which the operations commute. Our algorithm enables greater parallelism by permitting commuting operations to execute concurrently. We have implemented the synthesis algorithm in a Java compiler, and applied it to several Java programs. Our results show that our approach produces efficient and scalable synchronization.
- gee.cs.oswego.edu/dl/jsr166/dist/jsr166edocs/ jsr166e/ConcurrentHashMapV8.html.Google Scholar
- www.devdaily.com/java/jwarehouse/apache-tomcat- 6.0.16/java/org/apache/el/util/ConcurrentCache.java.shtml.Google Scholar
- guava-libraries. code.google.com/p/guava-libraries/.Google Scholar
- Wala. http://wala.sourceforge.net.Google Scholar
- B ERNSTEIN, P. A., H ADZILACOS, V., AND G OODMAN, N. Concurrency Control and Recovery in Database Systems. Addison-Wesley, 1987. Google Scholar
Digital Library
- C AO M INH, C., C HUNG, J., K OZYRAKIS, C., AND O LUKOTUN, K. STAMP: Stanford transactional applications for multi-processing. In IISWC (2008).Google Scholar
- C ASCAVAL, C., B LUNDELL, C., M ICHAEL, M., C AIN, H. W., W U, P., C HIRAS, S., AND C HATTERJEE, S. Software transactional memory: Why is it only a research toy? Queue 6, 5 (Sept. 2008), 46–58. Google Scholar
Digital Library
- G OLAN -G UETA, G., R AMALINGAM, G., S AGIV, M., AND Y AHAV, E. Concurrent libraries with foresight. In PLDI (2013). Google Scholar
Digital Library
- G UDKA, K., H ARRIS, T., AND E ISENBACH, S. Lock inference in the presence of large libraries. In ECOOP. 2012. Google Scholar
Digital Library
- H ARRIS, T., L ARUS, J., AND R AJWAR, R. Transactional memory, 2nd edition. Synthesis Lectures on Computer Architecture 5, 1 (2010). Google Scholar
Digital Library
- H AWKINS, P., A IKEN, A., F ISHER, K., R INARD, M., AND S AGIV, M. Concurrent data representation synthesis. In PLDI (2012). Google Scholar
Digital Library
- H ERLIHY, M., L EV, Y., L UCHANGCO, V., AND S HAVIT, N. A provably correct scalable concurrent skip list. In OPODIS (2006).Google Scholar
- H ERLIHY, M., AND S HAVIT, N. The Art of Multiprocessor Programming. Morgan Kauffman, Feb. 2008. Google Scholar
Digital Library
- H ERLIHY, M. P., AND W ING, J. M. Linearizability: A correctness condition for concurrent objects. TOPLAS 12 (1990). Google Scholar
Digital Library
- K ORLAND, G., S HAVIT, N., AND F ELBER, P. Noninvasive concurrency with java stm. In MULTIPROG (2010).Google Scholar
- K OSKINEN, E., P ARKINSON, M., AND H ERLIHY, M. Coarse-grained transactions. In POPL (2010), pp. 19–30. Google Scholar
Digital Library
- L HOTÁK, O., AND H ENDREN, L. Scaling java points-to analysis using spark. In Proceedings of the 12th international conference on Compiler construction (2003), CC’03. Google Scholar
Digital Library
- M C C LOSKEY, B., Z HOU, F., G AY, D., AND B REWER, E. Autolocker: synchronization inference for atomic sections. In POPL (2006). Google Scholar
Digital Library
- N IELSON, F., N IELSON, H. R., AND H ANKIN, C. Principles of Program Analysis. Springer-Verlag New York, Inc., 1999. Google Scholar
Digital Library
- S CHWARZ, P. M., AND S PECTOR, A. Z. Synchronizing shared abstract types. ACM Trans. Comput. Syst. 2, 3 (Aug. 1984), 223–250. Google Scholar
Digital Library
- S HACHAM, O., B RONSON, N., A IKEN, A., S AGIV, M., V ECHEV, M., AND Y AHAV, E. Testing atomicity of composed concurrent operations. In OOPSLA (2011). Google Scholar
Digital Library
Index Terms
Automatic scalable atomicity via semantic locking
Recommendations
Automatic scalable atomicity via semantic locking
PPoPP 2015: Proceedings of the 20th ACM SIGPLAN Symposium on Principles and Practice of Parallel ProgrammingIn this paper, we consider concurrent programs in which the shared state consists of instances of linearizable ADTs (abstract data types). We present an automated approach to concurrency control that addresses a common need: the need to atomically ...
Automatic Scalable Atomicity via Semantic Locking
Special Issue on PPoPP 2015 and Regular PapersIn this article, we consider concurrent programs in which the shared state consists of instances of linearizable abstract data types (ADTs). We present an automated approach to concurrency control that addresses a common need: the need to atomically ...
A Case for Non-Two-Phase Locking Protocols that Ensure Atomicity
A transaction is atomic if it can be considered, as far as other transactions are concerned, to be indivisible and instantaneous even in the case of failure. An almost universally accepted way to ensure atomicity is to use a strict two-phase locking ...






Comments