ABSTRACT
Transactional memory (TM) promises to substantially reduce the difficulty of writing correct, efficient, and scalable concurrent programs. But "bounded" and "best-effort" hardware TM proposals impose unreasonable constraints on programmers, while more flexible software TM implementations are considered too slow. Proposals for supporting "unbounded" transactions in hardware entail significantly higher complexity and risk than best-effort designs.We introduce Hybrid Transactional Memory (HyTM), an approach to implementing TMin software so that it can use best effort hardware TM (HTM) to boost performance but does not depend on HTM. Thus programmers can develop and test transactional programs in existing systems today, and can enjoy the performance benefits of HTM support when it becomes available.We describe our prototype HyTM system, comprising a compiler and a library. The compiler allows a transaction to be attempted using best-effort HTM, and retried using the software library if it fails. We have used our prototype to "transactify" part of the Berkeley DB system, as well as several benchmarks. By disabling the optional use of HTM, we can run all of these tests on existing systems. Furthermore, by using a simulated multiprocessor with HTM support, we demonstrate the viability of the HyTM approach: it can provide performance and scalability approaching that of an unbounded HTM implementation, without the need to support all transactions with complicated HTM support.
- A.-R. Adl-Tabatabai, B.T. Lewis, V. Menon, B.R. Murphy, B. Saha, and T. Shpeisman. Compiler and runtime support for efficient software transactional memory. In PLDI '06: Proceedings of the 2006 ACM SIGPLAN Conference on Programming Language Design and Implementation, pages 26--37, 2006. Google ScholarDigital Library
- A. Agarwal and M. Cherian. Adaptive backoff synchronization techniques. In Proc. 16th International Symposium on Computer Architecture, pages 396--406, May 1989. Google ScholarDigital Library
- C.S. Ananian, K. Asanovic, B.C. Kuszmaul, C.E. Leiserson, and S. Lie. Unbounded transactional memory. In Proc. 11th International Symposium on High-Performance Computer Architecture, pages 316--327, Feb. 2005. Google ScholarDigital Library
- B.D. Carlstrom, A. McDonald, H. Chafi, J. Chung, C.C. Minh, C. Kozyrakis, and K. Olukotun. The atomos transactional programming language. In PLDI '06: Proceedings of the 2006 ACMSIGPLAN conference on Programming language design and implementation, pages 1--13, New York, NY, USA, 2006. ACM Press. Google ScholarDigital Library
- D. Dice, O. Shalev, and N. Shavit. Transactional locking II. In Proc. International Symposium on Distributed Computing, 2006. To appear. Google ScholarDigital Library
- R. Guerraoui, M. Herlihy, and B. Pochon. Toward a theory of transactional contention managers. In Proc. 24th Annual ACM Symposium on Principles of Distributed Computing, pages 258--264, 2005. Google ScholarDigital Library
- L. Hammond, V. Wong, M. Chen, B.D. Carlstrom, J.D. Davis, B. Hertzberg, M.K. Prabhu, H. Wijaya, C. Kozyrakis, and K. Olukotun. Transactional memory coherence and consistency. In Proc. 31st Annual International Symposium on Computer Architecture, June 2004. Google ScholarDigital Library
- T. Harris and K. Fraser. Language support for lightweight transactions. In Proc. 18th Conference on Object-Oriented Programming, Systems, Languages, and Applications, pages 388--402, Oct. 2003. Google ScholarDigital Library
- T. Harris, M. Plesko, A. Shinnar, and D. Tarditi. Optimizing memory transactions. In PLDI '06: Proceedings of the 2006 ACM SIGPLAN Conference on Programming Language Design and Implementation, pages 14--25, New York, NY, USA, 2006. ACM Press. Google ScholarDigital Library
- M. Herlihy, V. Luchangco, M. Moir, and W.N. Scherer III. Software transactional memory for supporting dynamic-sized data structures. In Proc. 22th Annual ACM Symposium on Principles of Distributed Computing, pages 92--101, 2003. Google ScholarDigital Library
- M. Herlihy and J.E.B. Moss. Transactional memory: Architectural support for lock-free data structures. In Proc. 20th Annual International Symposium on Computer Architecture, pages 289--300, May 1993. Google ScholarDigital Library
- S. Kumar, M. Chu, C.J. Hughes, P. Kundu, and A. Nguyen. Hybrid transactional memory. In Proc. ACM SIGPLAN Symposium on Principles and Practice of Parallel Programming, Mar. 2006. Google ScholarDigital Library
- Y. Lev and M. Moir. Fast read sharing mechanism for software transactional memory, 2004. http://research.sun.com/scalable/pubs/PODC04-Poster.pdf.Google Scholar
- Y. Lev and M. Moir. Debuuging with transactional memory. Transact 2006 workshop, June 2006. http://research.sun.com/scalable/pubs/Lev-Moir-Debugging-2006.pdf.Google Scholar
- S. Lie. Hardware support for unbounded transactional memory. Master's thesis, Massachusetts Institute of Technology Department of Electrical Engineering and Computer Science, May 2004.Google Scholar
- P. Magnusson, F. Dahlgren, H. Grahn, M. Karlsson, F. Larsson, F. Lundholm, A. Moestedt, J. Nilsson, P. Stenstrom, and B. Werner. SimICS/sun4m: A virtual workstation. In Proceedings of the USENIX 1998 Annual Technical Conference (USENIX '98), June 1998. Google ScholarDigital Library
- M.M.K. Martin, D.J. Sorin, B.M. Beckmann, M.R. Marty, M. Xu, A.R. Alameldeen, K.E. Moore, M.D. Hill, and D.A. Wood. Multifacet's general execution-driven multiprocessor simulator (GEMS) toolset. SIGARCH Comput. Archit. News, 33(4):92--99, 2005. Google ScholarDigital Library
- J.F. Martinez and J. Torrellas. Speculative synchronization: Applying thread-level speculation to explicitly parallel applications. In Proc. 10th Symposium on Architectural Support for Programming Languages and Operating Systems, pages 18--29, 2002. Google ScholarDigital Library
- A. McDonald, J. Chung, B.D. Carlstrom, C.C. Minh, H. Chafi, C. Kozyrakis, and K. Olukotun. Architectural semantics for practical transactional memory. In ISCA '06: Proceedings of the 33rd International Symposium on Computer Architecture, pages 53--65, Washington, DC, USA, 2006. IEEE Computer Society. Google ScholarDigital Library
- M. Moir. Hybrid hardware/software transactional memory. Slides for Chicago Workshop on Transactional Systems, Apr. 2005. http://www.cs.wisc.edu/~rajwar/tm-workshop/TALKS/moir.pdf.Google Scholar
- M. Moir. Hybrid transactional memory, July 2005. http://research.sun.com/scalable/pubs/Moir-Hybrid-2005.pdf.Google Scholar
- K.E. Moore, J. Bobba, M.J. Moravan, M.D. Hill, and D.A. Wood. LogTM: Log-based transactional memory. In Proc. 12th Annual International Symposium on High Performance Computer Architecture, 2006.Google ScholarCross Ref
- K.E. Moore, M.D. Hill, and D.A. Wood. Thread-level transactional memory. Technical Report: CS-TR-2005-1524, Dept. of Computer Sciences, University of Wisconsin, Mar. 2005.Google Scholar
- M. Moravan, J. Bobba, K. Moore, L. Yen, M. Hill, B. Liblit, M. Swift, and D. Wood. Supporting nested transactional memory in LogTM. In Proc. 12th Symposium on Architectural Support for Programming Languages and Operating Systems, Oct. 2006. Google ScholarDigital Library
- M.A. Olson, K. Bostic, and M. Seltzer. Berkeley DB. In Proc. USENIX Annual Technical Conference, 1999. Google ScholarDigital Library
- R. Rajwar and J.R. Goodman. Speculative lock elision: Enabling highly concurrent multithreaded execution. In Proc. 34th International Symposium on Microarchitecture, pages 294--305, Dec. 2001. Google ScholarDigital Library
- R. Rajwar,M. Herlihy, and K. Lai. Virtualizing transactional memory. In Proc. 32nd Annual International Symposium on Computer Architecture, pages 494--505, Washington, DC, USA, 2005. Google ScholarDigital Library
- W. Scherer and M. Scott. Advanced contention management for dynamic software transactional memory. In Proc. 24th Annual ACM Symposium on Principles of Distributed Computing, 2005. Google ScholarDigital Library
- N. Shavit and D. Touitou. Software transactional memory. Distributed Computing, Special Issue(10):99--116, 1997.Google Scholar
- Sun Microsystems, Inc. http://www.sun.com/processors/ultrasparciv/index.xml.Google Scholar
- Sun Microsystems, Inc. Sun FireTM6800 Server. http://sunsolve.sun.com/handbookpub/Systems/SunFire6800/SunFire6800.html.Google Scholar
- M. Tremblay, Q. Jacobson, and S. Chaudhry. Selectively monitoring stores to support transactional program execution. US Patent Application 20040187115, Aug. 2003.Google Scholar
- S.C. Woo, M. Ohara, E. Torrie, J.P. Singh, and A. Gupta. The SPLASH-2 programs: characterization and methodological considerations. In Proc. 22nd Annual International Symposium on Computer Architecture, pages 24--36, 1995. Google ScholarDigital Library
Index Terms
- Hybrid transactional memory
Recommendations
Hybrid transactional memory
PPoPP '06: Proceedings of the eleventh ACM SIGPLAN symposium on Principles and practice of parallel programmingHigh performance parallel programs are currently difficult to write and debug. One major source of difficulty is protecting concurrent accesses to shared data with an appropriate synchronization mechanism. Locks are the most common mechanism but they ...
Hybrid transactional memory
Proceedings of the 2006 ASPLOS ConferenceTransactional memory (TM) promises to substantially reduce the difficulty of writing correct, efficient, and scalable concurrent programs. But "bounded" and "best-effort" hardware TM proposals impose unreasonable constraints on programmers, while more ...
Hybrid transactional memory
Proceedings of the 2006 ASPLOS ConferenceTransactional memory (TM) promises to substantially reduce the difficulty of writing correct, efficient, and scalable concurrent programs. But "bounded" and "best-effort" hardware TM proposals impose unreasonable constraints on programmers, while more ...
Comments