Abstract
This paper presents TransFinder, a compile-time tool that automatically determines which statements of an unsynchronized multithreaded program must be enclosed in atomic regions to enforce conflict-serializability. Unlike previous tools, TransFinder requires no programmer input (beyond the program) and is more efficient in both time and space.
Our implementation shows that the generated atomic regions range from being identical to, or smaller than, the programmer-specified transactions in the three Java Grande benchmarks considered, and in five of the eight STAMP benchmarks considered, while still providing identical synchronization semantics and results. The generated atomic regions are between 5 and 38 lines larger in the three remaining STAMP benchmarks. In the most conservative case, TransFinder can, based on the program structure, successfully identify and suggest an alternative that conforms exactly to the programmer-specified atomic regions. By generating small, highly-targeted, conflict-serializable atomic regions, TransFinder allows the programmer to focus further tuning efforts on only a small portion of the code (when further tuning is needed).
- }}D. Agrawal, J. L. Bruno, A. El Abbadi, and V. Krishnaswamy. Relative serializability (extended abstract): an approach for relaxing the atomicity of transactions. In PODS '94: Proceedings of the ACM Symposium on Principles of Database Systems, pages 139--149, New York, NY, USA, 1994. ACM. Google Scholar
Digital Library
- }}D. A. Bader and K. Madduri. Design and implementation of the hpcs graph analysis benchmark on symmetric multiprocessors. In HiPC '05: Proceedings of the High Performance Computing Conference, pages 465--476, 2005. Google Scholar
Digital Library
- }}R. Bayer. Consistency of transactions and random batch. ACM Transactions on Database Systems, 11(4):397--404, 1986. Google Scholar
Digital Library
- }}Brad Appleton. Sclc and Cdiff: Perl scripts for ClearCase. At http://www.cmcrossroads.com/broadapp/clearperl/sclc-cdiff.html.Google Scholar
- }}M. J. Cahill, U. Röhm, and A. D. Fekete. Serializable isolation for snapshot databases. In SIGMOD '08: Proceedings of the ACM International Conference on Management of Data, pages 729--738, New York, NY, USA, 2008. ACM. Google Scholar
Digital Library
- }}C. Cao Minh, J. Chung, C. Kozyrakis, and K. Olukotun. STAMP: Stanford transactional applications for multi-processing. In IISWC '08: Proceedings of The IEEE International Symposium on Workload Characterization, September 2008.Google Scholar
Cross Ref
- }}S. Cherem, T. M. Chilimbi, and S. Gulwani. Inferring locks for atomic sections. In PLDI '08: Proceedings of the ACM Conference on Programming Language Design and Implementation, pages 304--315, 2008. Google Scholar
Digital Library
- }}J.-D. Choi, K. Lee, A. Loginov, R. O'Callahan, V. Sarkar, and M. Sridharan. Efficient and precise datarace detection for multithreaded object-oriented programs. In PLDI '02: Proceedings of the ACM Conference on Programming Language Design and Implementation, pages 258--269, New York, NY, USA, 2002. ACM. Google Scholar
Digital Library
- }}M. Christiaens and K. De Bosschere. Trade, a topological approach to on-the-fly race detection in Java programs. In JVM'01: Proceedings of the 2001 Symposium on JavaTM Virtual Machine Research and Technology Symposium, pages 15--15, Berkeley, CA, USA, 2001. USENIX Association. Google Scholar
Digital Library
- }}R. Cytron, J. Ferrante, B. K. Rosen, M. N. Wegman, and F. K. Zadeck. Efficiently computing static single assignment form and the control dependence graph. ACM Transactions on Programming Languages and Systems, 13(4):451--490, 1991. Google Scholar
Digital Library
- }}D. Dice, O. Shalev, and N. Shavit. Transactional Locking II. In Proceedings of the International Symposium on Distributed Computing, pages 194--208, 2006. Google Scholar
Digital Library
- }}A. Dragojević, R. Guerraoui, and M. Kapalka. Stretching transactional memory. In PLDI '09: Proceedings of the ACM Conference on Programming Language Design and Implementation, pages 155--165, New York, NY, USA, 2009. ACM. Google Scholar
Digital Library
- }}R. Elmasri and S. B. Navathe. Fundamentals of Database Systems (5th Edition). Addison-Wesley Longman Publishing Co., Inc., Boston, MA, USA, 2006. Google Scholar
Digital Library
- }}M. Emmi, J. S. Fischer, R. Jhala, and R. Majumdar. Lock allocation. In POPL '07: Proceedings of the ACM Symposium on Principles of Programming Languages, pages 291--296, New York, NY, USA, 2007. ACM. Google Scholar
Digital Library
- }}EPCC. The Java Grande Forum Benchmark Suite. At http://www.epcc.ed.ac.uk/research/java-grande/. Last accessed March 24, 2010.Google Scholar
- }}P. Felber, C. Fetzer, and T. Riegel. Dynamic performance tuning of word-based software transactional memory. In PPoPP '08: Proceedings of the ACM Symposium on Principles and Practice of Parallel Programming, pages 237--246, New York, NY, USA, 2008. ACM. Google Scholar
Digital Library
- }}R. L. Halpert, C. J. Pickett, and C. Verbrugge. Component-based lock allocation. In PACT '07: Proceedings of the International Conference on Parallel Architectures and Compilation Techniques, pages 353--364, Los Alamitos, CA, USA, 2007. IEEE Computer Society. Google Scholar
Digital Library
- }}T. Harris, S. Marlow, S. Peyton-Jones, and M. Herlihy. Composable memory transactions. In PPoPP '05: Proceedings of the Tenth ACM SIGPLAN Symposium on Principles and Practice of Parallel Programming, pages 48--60, New York, NY, USA, 2005. ACM Press. Google Scholar
Digital Library
- }}M. Herlihy, V. Luchangco, M. Moir, and W. N. Scherer. Software transactional memory for dynamic-sized data structures. In PODC '03: Proceedings of the Symposium on Principles of Distributed Computing, pages 92--101, New York, NY, USA, 2003. ACM Press. Google Scholar
Digital Library
- }}M. Herlihy, J. E. B. Moss, J. Eliot, and B. Moss. Transactional memory: Architectural support for lock-free data structures. In Proceedings of the 20th Annual International Symposium on Computer Architecture, pages 289--300, 1993. Google Scholar
Digital Library
- }}M. Hicks, J. S. Foster, and P. Prattikakis. Lock inference for atomic sections. In Proceedings of the First ACM SIGPLAN Workshop on Languages, Compilers, and Hardware Support for Transactional Computing, June 2006.Google Scholar
- }}A. Krishnamurthy and K. Yelick. Analyses and optimizations for shared address space programs. Journal of Parallel and Distributed Computing, 38(2):130--144, 1996. Google Scholar
Digital Library
- }}J. Lee, D. A. Padua, and S. P. Midkiff. Basic compiler algorithms for parallel programs. In PPoPP '99: Proceedings of the ACM SIGPLAN Symposium on Principles and Practice of Parallel Programming, pages 1--12, 1999. Google Scholar
Digital Library
- }}O. Lhoták and L. Hendren. Scaling Java points-to analysis using Spark. In G. Hedin, editor, Proceedings of the International Conference on Compiler Construction, volume 2622 of LNCS, pages 153--169, Warsaw, Poland, April 2003. Springer. Google Scholar
Digital Library
- }}B. McCloskey, F. Zhou, D. Gay, and E. Brewer. Autolocker: synchronization inference for atomic sections. In POPL '06: Proceedings of the ACM Symposium on Principles of Programming Languages, pages 346--358, New York, NY, USA, 2006. ACM. Google Scholar
Digital Library
- }}M. Moir, K. Moore, and D. Nussbaum. The adaptive transactional memory test platform: a tool for experimenting with transactional code for rock (poster). In SPAA '08: Proceedings of the Symposium on Parallelism in Algorithms and Architectures, pages 362--362, 2008. Google Scholar
Digital Library
- }}M. Naik, A. Aiken, and J. Whaley. Effective static race detection for java. In PLDI '06: Proceedings of the ACM Conference on Programming Language Design and Implementation, pages 308--319, New York, NY, USA, 2006. ACM. Google Scholar
Digital Library
- }}R. O'Callahan and J.-D. Choi. Hybrid dynamic data race detection. In PPoPP '03: Proceedings of the ACM Symposium on Principles and Practice of Parallel Programming, pages 167--178, New York, NY, USA, 2003. ACM. Google Scholar
Digital Library
- }}M. C. Rinard and P. C. Diniz. Commutativity analysis: A new analysis technique for parallelizing compilers. ACM Transactions on Programming Languages and Systems, 19(6):1--47, 1997. Google Scholar
Digital Library
- }}S. Savage, M. Burrows, G. Nelson, P. Sobalvarro, and T. Anderson. Eraser: a dynamic data race detector for multithreaded programs. ACM Transactions on Computer Systems, 15(4):391--411, 1997. Google Scholar
Digital Library
- }}D. Shasha, F. Llirbat, E. Simon, and P. Valduriez. Transaction chopping: algorithms and performance studies. ACM Transactions on Database Systems, 20(3):325--363, 1995. Google Scholar
Digital Library
- }}D. Shasha and M. Snir. Efficient and correct execution of parallel programs that share memory. ACM Transactions on Programming Languages and Systems, 10(2):282--312, April 1988. Google Scholar
Digital Library
- }}N. Shavit and D. Touitou. Software transactional memory. In Proceedings of the Symposium on Principles of Distributed Computing, pages 204--213, 1995. Google Scholar
Digital Library
- }}T. Shpeisman, V. Menon, A.-R. Adl-Tabatabai, S. Balensiefer, D. Grossman, R. L. Hudson, K. F. Moore, and B. Saha. Enforcing isolation and ordering in S™. In PLDI '07: Proceedings of the ACM Conference on Programming Language Design and Implementation, pages 78--88, New York, NY, USA, 2007. Google Scholar
Digital Library
- }}G. Upadhyaya, S. P. Midkiff, and V. S. Pai. Using data structure knowledge for efficient lock generation and strong atomicity. In PPoPP '10: Proceedings of the ACM Symposium on Principles and Practice Of Parallel Programming, pages 281--292, 2010. Google Scholar
Digital Library
- }}R. Vallee-Rai, E. Gagnon, L. J. Hendren, P. Lam, P. Pominville, and V. Sundaresan. Optimizing Java bytecode using the Soot framework: Is it feasible? In Proceedings of the International Conference on Compiler Construction (CC '09), pages 18--34, 2000. Google Scholar
Digital Library
- }}M. T. Vechev, E. Yahav, and G. Yorsh. Inferring synchronization under limited observability. In TACAS '09: Proceedings of the International Conference on Tools and Algorithms for the Construction and Analysis of Systems, pages 139--154, 2009. Google Scholar
Digital Library
- }}M. T. Vechev, E. Yahav, and G. Yorsh. Abstraction-guided synthesis of synchronization. In POPL '10: Proceegings of the ACM Symposium on Principles of Programming Languages, pages 327--338, 2010. Google Scholar
Digital Library
- }}H. Volos, N. Goyal, and M. Swift. Pathological interaction of locks with transactional memory. In Proceedings of the ACM Workshop on Transactional Computing (TRANSACT) '08, 2008. article available at http://www.unine.ch/transact08/papers/Volos-Pathological.pdf. URL last checked on Nov. 19, 2009.Google Scholar
- }}O. Wolfson. The virtues of locking by symbolic names. Journal of Algorithms, 8(4):536--556, 1987. Google Scholar
Digital Library
- }}Y. Zhang, V. C. Sreedhar, W. Zhu, V. Sarkar, and G. R. Gao. Minimum lock assignment: A method for exploiting concurrency among critical sections. In Proceedings of the 21st Annual Workshop on Languages and Compilers for Parallel Computing (LCPC '08), 2008. Google Scholar
Digital Library
- }}L. Ziarek, A. Welc, A.-R. Adl-Tabatabai, V. Menon, T. Shpeisman, and S. Jagannathan. A uniform transactional execution environment for Java. In ECOOP '08: Proceedings of the European Conference on Object-Oriented Programming, pages 129--154, 2008. Google Scholar
Digital Library
Index Terms
Automatic atomic region identification in shared memory SPMD programs
Recommendations
Automatic atomic region identification in shared memory SPMD programs
OOPSLA '10: Proceedings of the ACM international conference on Object oriented programming systems languages and applicationsThis paper presents TransFinder, a compile-time tool that automatically determines which statements of an unsynchronized multithreaded program must be enclosed in atomic regions to enforce conflict-serializability. Unlike previous tools, TransFinder ...
Hardware Support for Relaxed Concurrency Control in Transactional Memory
MICRO '43: Proceedings of the 2010 43rd Annual IEEE/ACM International Symposium on MicroarchitectureToday's transactional memory systems implement the two-phase-locking (2PL) algorithm which aborts transactions every time a conflict happens. 2PL is a simple algorithm that provides fast transactional operations. However, it limits concurrency in ...
Unbounded page-based transactional memory
Proceedings of the 2006 ASPLOS ConferenceExploiting thread level parallelism is paramount in the multicore era. Transactions enable programmers to expose such parallelism by greatly simplifying the multi-threaded programming model. Virtualized transactions (unbounded in space and time) are ...







Comments