skip to main content
research-article

Safe compiler-driven transaction checkpointing and recovery

Published:19 October 2012Publication History
Skip Abstract Section

Abstract

Several studies have shown that a large fraction of the work performed inside memory transactions in representative programs is wasted due to the transaction experiencing a conflict and aborting. Aborts inside long running transactions are especially influential to performance and the simplicity of the TM programming model (relative to using finegrained locking) in synchronizing large critical sections means that large transactions are common and this exacerbates the problem of wasted work. In this paper we present a practical transaction checkpoint and recovery scheme in which transactions that experience a conflict can restore their state (including the local context in which they were executing) to some dynamic program point before this access and begin execution from that point. This state saving and restoration is implemented by checkpoint operations that are generated by a compiler into the transaction's body and are also optimized to reduce the amount of state that is saved and restored. We also describe a runtime system that manages these checkpointed states and orchestrates the restoration of the right checkpointed state for a conflict on a particular transactional access. Moreover the synthesis of these save and restore operations, their optimization and invocation at runtime are completely transparent to the programmer. We have implemented the checkpoint generation and optimization scheme in the LLVM compiler and runtime support for the TL2 STM system. Our experiments indicate that for many parallel programs using such checkpoint recovery schemes can result in upto several orders of magnitude reduction in number of aborts and significant execution time speedups relative to plain transactional programs for the same number of threads.

References

  1. Acar U.A., Hammer M.A., Chen. Y, "CEAL: A C-Based Language for Self-Adjusting Computation". In Proceedings of the International Conference on Programming language design and implementation (PLDI) 2009. Google ScholarGoogle ScholarDigital LibraryDigital Library
  2. Minh C.C., Chung J., Kozyrakis K., Olukotun K., "STAMP: Stanford Transactional Applications for Multi-Processing". In IISWC 2008 35--46Google ScholarGoogle Scholar
  3. Kulkarni M., Pingali K., Walter B., Ramanarayanan G., Bala K., Chew L.P., "Optimistic parallelism requires abstractions". In the International Conference on Programming Language and Design 2007 Google ScholarGoogle ScholarDigital LibraryDigital Library
  4. Felber P., Fetzer C., and Riegel T., "Dynamic Performance Tuning of Word-Based Software Transactional Memory". In Proceedings of the 13th ACM SIGPLAN Symposium on Principles and Practice of Parallel Programming (PPoPP) 2008 Google ScholarGoogle ScholarDigital LibraryDigital Library
  5. Herlihy M., Luchangco V., Moir M., and Scherer W.N., "Software transactional memory for dynamic-sized data structures". InProceedings of the twenty-second annual symposium on Principles of distributed computing (PODC '03) Google ScholarGoogle ScholarDigital LibraryDigital Library
  6. Phatak, S.H. and Badrinath, B.R. "Multiversion Reconciliation for Mobile Databases" in Proceedings of the 15th international Conference on Data Engineering 1999. Google ScholarGoogle ScholarDigital LibraryDigital Library
  7. W. N. Scherer III and M. L. Scott, "Advanced Contention Management for Dynamic Software Transactional Memory" in Symp. on Principles of Distributed Computing, Las Vegas, NV, 2005 Google ScholarGoogle ScholarDigital LibraryDigital Library
  8. The LLVM Compiler Infrastructure, www.llvm.orgGoogle ScholarGoogle Scholar
  9. T. Harris and S. Stipic "Abstract Nested Transactions", in 2nd Workshop on Transactional Computing (TRANSACT 07).Google ScholarGoogle Scholar
  10. Ramadan, H. E., Roy, I., Herlihy, M., Witchel, E, "Committing Conflicting Transactions in an STM", International Symposium on the Principles and Practice of Parallel Programming (PPOPP) 2009. Google ScholarGoogle ScholarDigital LibraryDigital Library
  11. M. Herlihy and E. Koskinen "Checkpoints and continuations instead of nested transactions", in the 3rd Workshop on Transactional ComputingGoogle ScholarGoogle Scholar
  12. Dmitri Perelman and Idit Keidar, "On Avoiding Spare Aborts in Transactional Memory", in Proc. 21st Symposium on Parallelism in Algorithms and Architectures (SPAA) 2009. Google ScholarGoogle ScholarDigital LibraryDigital Library
  13. Guerraoui R., and Kapalka M., On the correctness of transactional memory. In Principles and Practice of Parallel Programming (PoPP) 2008. Google ScholarGoogle ScholarDigital LibraryDigital Library
  14. Moss, J. E. and Hosking, A. L. 2006. "Nested transactional memory: model and architecture sketches". In Science of Computer Programming 63, 2 (Dec. 2006), 186--201 Google ScholarGoogle ScholarDigital LibraryDigital Library
  15. Blundell C., Raghavan A., Martin M.K., "RETCON: transactional repair without replay". In Proceedings of the 37th annual international symposium on Computer architecture (ISCA '10) Google ScholarGoogle ScholarDigital LibraryDigital Library
  16. Herlihy, M. and Koskinen, E., "Transactional boosting: a methodology for highly-concurrent transactional objects". In Symposium on Principles and Practice of Parallel Programming 2008. Google ScholarGoogle ScholarDigital LibraryDigital Library
  17. Ramalingam G. and Reps T., A Categorized Bibliography on Incremental Computation. In Proceedings of the 20th Annual ACM Symposium on Principles of Programming Languages pages 502--"510, 1993. Google ScholarGoogle ScholarDigital LibraryDigital Library
  18. Bieniusa A., Middelkoop A., Thiemann P., "Actions in the Twilight: Concurrent irrevocable transactions and Inconsistency repair". Technical Report 257, Insitut fur Informatik, Universitat Freiburg, 2010Google ScholarGoogle Scholar
  19. Pugh, W. and Teitelbaum, T., "Incremental computation via function caching". In Proceedings of the 16th ACM SIGPLAN-SIGACT Symposium on Principles of Programming Languages 1989. Google ScholarGoogle ScholarDigital LibraryDigital Library
  20. Waliullah M.M. and Stenstrom P., "Intermediate Checkpointing with Conflicting Access Prediction in Transactional Memory Systems". In Proceedings of the 22nd IEEE International Parallel and Distributed Processing Symposium 2008.Google ScholarGoogle ScholarCross RefCross Ref
  21. Zyulkyarov F., Stipic S., Harris T., Unsal O.S., Cristal A., Hur I., and Valero M. "Discovering and understanding performance bottlenecks in transactional applications PACT 2010 Google ScholarGoogle ScholarDigital LibraryDigital Library
  22. Yellin, D. M., Strom, R. E., "INC: a language for incremental computations" ACM Transactions on Programming Languages and Systems 13, 2 (Apr. 1991), 211--236. Google ScholarGoogle ScholarDigital LibraryDigital Library
  23. Dice D., Shalev O., Shavit N., "Transactional Locking II". In proceedings of the 20th International Symposium on Distributed Computing (DISC), Stockholm, Sweeden, Sept. 2006. Google ScholarGoogle ScholarDigital LibraryDigital Library

Index Terms

  1. Safe compiler-driven transaction checkpointing and recovery

      Recommendations

      Comments

      Login options

      Check if you have access through your login credentials or your institution to get full access on this article.

      Sign in

      Full Access

      • Published in

        cover image ACM SIGPLAN Notices
        ACM SIGPLAN Notices  Volume 47, Issue 10
        OOPSLA '12
        October 2012
        1011 pages
        ISSN:0362-1340
        EISSN:1558-1160
        DOI:10.1145/2398857
        Issue’s Table of Contents
        • cover image ACM Conferences
          OOPSLA '12: Proceedings of the ACM international conference on Object oriented programming systems languages and applications
          October 2012
          1052 pages
          ISBN:9781450315616
          DOI:10.1145/2384616

        Copyright © 2012 ACM

        Publisher

        Association for Computing Machinery

        New York, NY, United States

        Publication History

        • Published: 19 October 2012

        Check for updates

        Qualifiers

        • research-article

      PDF Format

      View or Download as a PDF file.

      PDF

      eReader

      View online with eReader.

      eReader
      About Cookies On This Site

      We use cookies to ensure that we give you the best experience on our website.

      Learn more

      Got it!