Skip to main content
Log in

An abort-aware model of transactional programming

  • VMCAI 2009
  • Published:
International Journal on Software Tools for Technology Transfer Aims and scope Submit manuscript

Abstract

There has been a lot of recent research on transaction-based concurrent programming, aimed at offering an easier concurrent programming paradigm that enables programmers to better exploit the parallelism of modern multi-processor machines, such as multi-core microprocessors. We introduce Transactional State Machines (TSMs) as an abstract finite-data model of transactional shared-memory concurrent programs. TSMs are a variant of concurrent boolean programs (or concurrent extended recursive state machines) augmented with additional constructs for specifying potentially nested transactions. Namely, some procedures (or code segments) can be marked as transactions and are meant to be executed “atomically”, and there are also explicit commit and abort operations for transactions. The TSM model is non-blocking and allows interleaved executions where multiple processes can simultaneously be executing inside transactions. It also allows nested transactions, transactions which may never terminate, and transactions which may be aborted explicitly, or aborted automatically by the run-time environment due to memory conflicts. We show that concurrent executions of TSMs satisfy a correctness criterion closely related to serializability, which we call stutter-serializability, with respect to shared memory. We initiate a study of model checking problems for TSMs. Model checking arbitrary TSMs is easily seen to be undecidable, but we show it is decidable in the following case: when recursion is exclusively used inside transactions in all (but one) of the processes, we show that model checking such TSMs against all stutter-invariant ω-regular properties of shared memory is decidable.

This is a preview of subscription content, log in via an institution to check access.

Access this article

Price excludes VAT (USA)
Tax calculation will be finalised during checkout.

Instant access to the full article PDF.

Similar content being viewed by others

References

  1. Abadi, M., Birrell, A., Harris, T., Isard, M.: Semantics of transactional memory and automatic mutual exclusion. In: Proceedings of POPL’08 (2008)

  2. Alur R., Benedikt M., Etessami K., Godefroid P., Reps T., Yannakakis M.: Analysis of recursive state machines. ACM Trans. Program. Lang. Syst. 27(4), 786–818 (2005)

    Article  Google Scholar 

  3. Alur, R., Chaudhuri, S., Etessami, K., Madhusudan, P.: On-the-fly reachability and cycle detection for recursive state machines. In: TACAS, pp. 61–76 (2005)

  4. Alur R., McMillan K.L., Peled D.: Model-checking of correctness conditions for concurrent objects. Inf. Comput. 160(1-2), 167–188 (2000)

    Article  MathSciNet  MATH  Google Scholar 

  5. Ball, T., Rajamani, S.: Bebop: a symbolic model checker for boolean programs. In: SPIN’2000. LNCS, vol. 1885, pp. 113–130 (2000)

  6. Bernstein P., Hadzilacos V., Goodman N.: Concurrency control and Recovery in Database Systems. Addison-Wesley, Reading (1987)

    Google Scholar 

  7. Bobba, J., Rajwar, R., Hill, M. (eds.): Transactional memory bibliography (online). http://www.cs.wisc.edu/trans-memory/biblio

  8. Bouajjani, A., Esparza, J., Touili, T.: A generic approach to the static analysis of concurrent programs with procedures. In: Proceedings of POPL’03 (2003)

  9. Cohen, A., O’Leary, J.W., Pnueli, A., Tuttle, M.R., Zuck, L.D.: Verifying correctness of transactional memories. In: Proceedings of FMCAD’2007 (Formal Methods in Computer-Aided Design) (2007)

  10. Etessami, K.: Stutter-invariant languages, ω-automata, and temporal logic. In: Proceedings of the 11th International Conference on Computer Aided Verification, pp. 236–248 (1999)

  11. Grossman, D., Manson, J., Pugh, W.: What do high-level memory models mean for transactions? In: MSPC’06, pp. 62–69 (2006)

  12. Guerraoui, R., Henzinger, T.A., Jobstmann, B., Singh, V.: Model checking transactional memories. In: ACM SIGPLAN 2008 Conference on Programming Language Design and Implementation (PLDI) (2008)

  13. Guerraoui, R., Kapalka, M.: On the correctness of transactional memory. In: Proceedings of 13th ACM Symposium on Principles and Practice of Parallel Programming (PPOPP), pp. 175–184 (2008)

  14. Kahlon, V., Ivancic, F., Gupta, A.: Reasoning about threads communicating via locks. In: Proceedings of CAV’05 (2005)

  15. Lamport, L.: What good is temporal logic. In: Mason, R.E.A. (ed.) Information Processing ’83: Proc. IFIP 9th World Computer Congress, pp. 657–668 (1983)

  16. Larus J., Rajwar R.: Transactional Memory. Morgan & Claypool, New York (2007)

    Google Scholar 

  17. Manovit, C., Hangal, S., Chafi, H., McDonald, A., Kozyrakis, C., Olukotun, K.: Testing implementations of transactional memory. In: Proceedings of the 15th international conference on Parallel architectures and compilation techniques (2007)

  18. Moore, K.F., Grossman, D.: High-level small-step operational semantics for transactions. In: Proceedings of POPL’08 (2008)

  19. Peled D., Wilke Th.: Stutter-invariant temporal properties are expressible without the next-time operator. Inf. Process. Lett. 63, 243–246 (1997)

    Article  MathSciNet  Google Scholar 

  20. Qadeer, S., Rajamani, S.K., Rehof, J.: Summarizing procedures in concurrent programs. In: Proceedings of POPL’04 (2004)

  21. Ramalingam G.: Context-sensitive synchronization-sensitive analysis is undecidable. ACM Trans. Program. Lang. Syst. 22(2), 416–430 (2000)

    Article  Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Kousha Etessami.

Additional information

The work of K. Etessami was done partly while visiting Microsoft Research.

Rights and permissions

Reprints and permissions

About this article

Cite this article

Etessami, K., Godefroid, P. An abort-aware model of transactional programming. Int J Softw Tools Technol Transfer 13, 537–551 (2011). https://doi.org/10.1007/s10009-011-0203-0

Download citation

  • Published:

  • Issue Date:

  • DOI: https://doi.org/10.1007/s10009-011-0203-0

Keywords

Navigation