Skip to main content

A Composable Mixed Mode Concurrency Control Semantics for Transactional Programs

  • Conference paper

Part of the Lecture Notes in Computer Science book series (LNPSE,volume 7635)

Abstract

Most software transactional memories employ optimistic concurrency control. A pessimistic semantics, however, is not without its benefits: its programming model is often much simpler to reason about and supports the execution of irreversible operations. We present a programming model that supports both optimistic and pessimistic concurrency control semantics. Our pessimistic transactions, guaranteed transactions (gatomics), afford a stronger semantics than that typically employed by pessimistic transactions by guaranteeing run once execution and safe encapsulation of the privatisation and publication idioms. We describe our mixed mode transactional programming language by giving a small step operational semantics. Using our semantics and their derived schedules of actions (reads and writes) we show that conflicting transactions (atomics) and gatomics are serialisable. We then go on to define schedules of actions in the form of Java’s memory model (JMM) and show that the same properties that held under our restrictive memory model also hold under our modified JMM.

Keywords

  • Memory Model
  • Operational Semantic
  • Concurrency Control
  • Sequential Consistency
  • Software Transactional Memory

These keywords were added by machine and not by the authors. This process is experimental and the keywords may be updated as the learning algorithm improves.

This is a preview of subscription content, access via your institution.

Buying options

Chapter
USD   29.95
Price excludes VAT (Canada)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
eBook
USD   39.99
Price excludes VAT (Canada)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
USD   54.99
Price excludes VAT (Canada)
  • Compact, lightweight edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info

Tax calculation will be finalised at checkout

Purchases are for personal use only

Learn about institutional subscriptions

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

References

  1. Abadi, M., Birrell, A., Harris, T., Isard, M.: Semantics of transactional memory and automatic mutual exclusion. In: Principles of Programming Languages (2008)

    Google Scholar 

  2. Adve, S.V., Gharachorloo, K.: Shared memory consistency models: A tutorial. Computer (1996)

    Google Scholar 

  3. Adve, S.V., Hill, M.D.: Weak ordering – a new definition. In: International Symposium on Computer Architecture (1990)

    Google Scholar 

  4. Agrawal, R., Carey, M.J., Livny, M.: Concurrency control performance modeling: alternatives and implications. ACM Trans. Database Syst. (1987)

    Google Scholar 

  5. Andersen, L.O.: Program analysis and specialization for the c programming language. Technical report. University of Copenhagen (1994)

    Google Scholar 

  6. Blundell, C., Christopher Lewis, E., Martin, M.M.K.: Deconstructing transactional semantics: The subtleties of atomicity. In: Workshop on Duplicating, Deconstructing, and Debunking (2005)

    Google Scholar 

  7. Blundell, C., Devietti, J., Christopher Lewis, E., Martin, M.M.K.: Making the fast case common and the uncommon case simple in unbounded transactional memory. In: International Symposium on Computer Architecture (2007)

    Google Scholar 

  8. Gray, J.: The transaction concept: virtues and limitations. Very Large Data Bases (1981)

    Google Scholar 

  9. Grossman, D., Manson, J., Pugh, W.: What do high-level memory models mean for transactions? In: Memory System Performance and Correctness (2006)

    Google Scholar 

  10. Harris, T., Marlow, S., Peyton-Jones, S., Herlihy, M.: Composable memory transactions. In: Principles and Practice of Parallel Programming (2005)

    Google Scholar 

  11. Harris, T., Larus, J., Rajwar, R.: Transactional memory, 2nd edn. (2010)

    Google Scholar 

  12. Herlihy, M., Luchangco, V., Moir, M., Scherer III, W.N.: Software transactional memory for dynamic-sized data structures. In: Principles of Distributed Computing (2003)

    Google Scholar 

  13. Hickey, R.: The clojure programming language. In: Dynamic Languages Symposium (2008)

    Google Scholar 

  14. Isard, M., Birrell, A.: Automatic mutual exclusion. In: USENIX (2007)

    Google Scholar 

  15. Jenista, J., Demsky, B.: Disjointness analysis for java-like languages. Technical report, University of California, Irvine (2009)

    Google Scholar 

  16. Koskinen, E., Parkinson, M., Herlihy, M.: Coarse-grained transactions. In: Principles of Programming Languages (2010)

    Google Scholar 

  17. Lamport, L.: How to make a multiprocessor computer that correctly executes multiprocess programs. Transactions on Computers (1979)

    Google Scholar 

  18. Lamport, L.: Time, clocks, and the ordering of events in a distributed system. Commun. ACM (1978)

    Google Scholar 

  19. Manson, J., Pugh, W., Adve, S.V.: The java memory model. In: Principles of Programming Languages (2005)

    Google Scholar 

  20. Marron, M., Méndez-Lojo, M., Hermenegildo, M., Stefanovic, D., Kapur, D.: Sharing analysis of arrays, collections, and recursive structures. In: Program Analysis for Software Tools and Engineering (2008)

    Google Scholar 

  21. McCloskey, B., Zhou, F., Gay, D., Brewer, E.: Autolocker: synchronization inference for atomic sections. In: Principles of Programming Languages (2006)

    Google Scholar 

  22. Menon, V., Balensiefer, S., Shpeisman, T., Adl-Tabatabai, A.-R., Hudson, R.L., Saha, B., Welc, A.: Practical weak-atomicity semantics for java stm. In: Symposium on Parallelism in Algorithms and Architectures (2008)

    Google Scholar 

  23. Ni, Y., Welc, A., Adl-Tabatabai, A.-R., Bach, M., Berkowits, S., Cownie, J., Geva, R., Kozhukow, S., Narayanaswamy, R., Olivier, J., Preis, S., Saha, B., Tal, A., Tian, X.: Design and implementation of transactional constructs for c/c++. In: Object-Oriented Programming Systems Languages and Applications (2008)

    Google Scholar 

  24. Papadimitriou, C.H.: The serializability of concurrent database updates. J. ACM (1979)

    Google Scholar 

  25. Pugh, W., Wonnacott, D.: Constraint-based array dependence analysis. Transactions on Programming Languages and Systems (1998)

    Google Scholar 

  26. Shavit, N., Matveev, A.: Towards a fully pessimistic stm model. Transactional Computing (2012)

    Google Scholar 

  27. Shavit, N., Touitou, D.: Software transactional memory. In: Principles of Distributed Computing (1995)

    Google Scholar 

  28. Smaragdakis, Y., Kay, A., Behrends, R., Young, M.: Transactions with isolation and cooperation. In: Object-Oriented Programming Systems Languages and Applications (2007)

    Google Scholar 

  29. Sonmez, N., Harris, T., Cristal, A., Unsal, O.S., Valero, M.: Taking the heat off transactions: Dynamic selection of pessimistic concurrency control. In: International Symposium on Parallel and Distributed Processing (2009)

    Google Scholar 

  30. Spear, M.F., Marathe, V.J., Daless, L., Scott, M.L.: Privatization techniques for software transactional memory. In: Principles of Distributed Computing (2007)

    Google Scholar 

  31. Welc, A., Saha, B., Adl-Tabatabai, A.-R.: Irrevocable transactions and their applications. In: Symposium on Parallelism in Algorithms and Architectures (2008)

    Google Scholar 

  32. Ziarek, L., Welc, A., Adl-Tabatabai, A.-R., Menon, V., Shpeisman, T., Jagannathan, S.: A Uniform Transactional Execution Environment for Java. In: Dell’Acqua, P. (ed.) ECOOP 2008. LNCS, vol. 5142, pp. 129–154. Springer, Heidelberg (2008)

    CrossRef  Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Editor information

Editors and Affiliations

Rights and permissions

Reprints and Permissions

Copyright information

© 2012 Springer-Verlag Berlin Heidelberg

About this paper

Cite this paper

Barnett, G., Qin, S. (2012). A Composable Mixed Mode Concurrency Control Semantics for Transactional Programs. In: Aoki, T., Taguchi, K. (eds) Formal Methods and Software Engineering. ICFEM 2012. Lecture Notes in Computer Science, vol 7635. Springer, Berlin, Heidelberg. https://doi.org/10.1007/978-3-642-34281-3_6

Download citation

  • DOI: https://doi.org/10.1007/978-3-642-34281-3_6

  • Publisher Name: Springer, Berlin, Heidelberg

  • Print ISBN: 978-3-642-34280-6

  • Online ISBN: 978-3-642-34281-3

  • eBook Packages: Computer ScienceComputer Science (R0)