Advertisement

Algorithmic Techniques in STM Design

  • Panagiota Fatourou
  • Mykhailo Iaremko
  • Eleni Kanellou
  • Eleftherios Kosmas
Part of the Lecture Notes in Computer Science book series (LNCS, volume 8913)

Abstract

The Transactional Memory paradigm has gained a lot of momentum in recent years. This is evidenced by the plethora of software transactional memory (STM) algorithms that can be found in the literature. Although their goal is common - to offer the transaction abstraction to the programmer - the implementations that they provide for this abstraction show a great variation among them. This variation appears as different algorithms aim at exhibiting different additional properties, such as offering specific liveness guarantees or good performance or both. In this chapter, we identify the basic characteristics of STM algorithms and the mechanisms that they are made up from. In conjunction with the design decisions, and in order to outline how they are used, we present in detail some representative STM algorithms. We also briefly discuss a lot of other STM algorithms found in the literature.

Keywords

Data Item Incremental Validation Transactional Memory Algorithmic Technique 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.

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

References

  1. 1.
    Abadi, M., Birrell, A., Harris, T., Isard, M.: Semantics of transactional memory and automatic mutual exclusion. ACM Trans. Program. Lang. Syst. 33(1), 2:1–2:50 (2011)Google Scholar
  2. 2.
    Adl-Tabatabai, A.R., Lewis, B.T., Menon, V., Murphy, B.R., Saha, B., Shpeisman, T.: Compiler and runtime support for efficient software transactional memory. SIGPLAN Not 41(6), 26–37 (2006)CrossRefGoogle Scholar
  3. 3.
    Afek, Y., Avni, H., Dice, D., Shavit, N.: Efficient lock free privatization. In: Lu, C., Masuzawa, T., Mosbah, M. (eds.) OPODIS 2010. LNCS, vol. 6490, pp. 333–347. Springer, Heidelberg (2010)CrossRefGoogle Scholar
  4. 4.
    Afek, Y., Matveev, A., Shavit, N.: Pessimistic software lock-elision. In: Aguilera, M.K. (ed.) DISC 2012. LNCS, vol. 7611, pp. 297–311. Springer, Heidelberg (2012)CrossRefGoogle Scholar
  5. 5.
    Agrawal, K., Fineman, J.T., Sukha, J.: Nested parallelism in transactional memory. In: Proceedings of the 13th ACM SIGPLAN Symposium on Principles and Practice of Parallel Programming (PPoPP), pp. 163–174. ACM, New York (2008)Google Scholar
  6. 6.
    Attiya, H., Epstein, L., Shachnai, H., Tamir, T.: Transactional contention management as a non-clairvoyant scheduling problem. In: Proceedings of the 25th ACM Symposium on Principles of Distributed Computing (PODC), pp. 308–315. ACM, New York (2006)Google Scholar
  7. 7.
    Attiya, H., Hans, S.: Transactions are back—but how different they are? In: 7th ACM SIGPLAN Workshop on Transactional Computing (Transact), New Orleans, LA, USA (February 2012)Google Scholar
  8. 8.
    Attiya, H., Hans, S., Kuznetsov, P., Ravi, S.: Safety of deferred update in transactional memory. CoRR abs/1301.6297 (2013), http://arxiv.org/abs/1301.6297
  9. 9.
    Attiya, H., Hillel, E.: A single-version STM that is multi-versioned permissive. Theory Comput. Syst. 51(4), 425–446 (2012)MathSciNetCrossRefzbMATHGoogle Scholar
  10. 10.
    Avni, H., Shavit, N.N.: Maintaining consistent transactional states without a global clock. In: Shvartsman, A.A., Felber, P. (eds.) SIROCCO 2008. LNCS, vol. 5058, pp. 131–140. Springer, Heidelberg (2008)CrossRefGoogle Scholar
  11. 11.
    Bloom, B.H.: Space/time trade-offs in hash coding with allowable errors. Commun. ACM 13(7), 422–426 (1970)CrossRefzbMATHGoogle Scholar
  12. 12.
    Bushkov, V., Dziuma, D., Fatourou, P., Guerraoui, R.: The pcl theorem: Transactions cannot be parallel, consistent and live. In: Proceedings of the 26th ACM Symposium on Parallelism in Algorithms and Architectures (SPAA), pp. 178–187. ACM, New York (2014)Google Scholar
  13. 13.
    Dalessandro, L., Spear, M.F., Scott, M.L.: Norec: streamlining stm by abolishing ownership records. In: Proceedings of the 15th ACM SIGPLAN Symposium on Principles and Practice of Parallel Programming (PPoPP), pp. 67–78. ACM, New York (2010)Google Scholar
  14. 14.
    Dice, D., Shavit, N.: What really makes transactions faster? In: 1st ACM SIGPLAN Workshop on Transactional Computing (Transact), Ottawa, Canada (June 2006)Google Scholar
  15. 15.
    Dice, D., Shalev, O., Shavit, N.: Transactional locking II. In: Dolev, S. (ed.) DISC 2006. LNCS, vol. 4167, pp. 194–208. Springer, Heidelberg (2006)CrossRefGoogle Scholar
  16. 16.
    Dice, D., Shavit, N.: Tlrw: return of the read-write lock. In: Proceedings of the 22nd ACM symposium on Parallelism in Algorithms and Architectures (SPAA), pp. 284–293. ACM, New York (2010)CrossRefGoogle Scholar
  17. 17.
    Doherty, S., Groves, L., Luchangco, V., Moir, M.: Towards formally specifying and verifying transactional memory. Formal Aspects of Computing 25(5), 769–799 (2013)MathSciNetCrossRefzbMATHGoogle Scholar
  18. 18.
    Dolev, S., Fatourou, P., Kosmas, E.: Abort free SemanticTM by dependency aware scheduling of transactional instructions. In: 8th ACM SIGPLAN Workshop on Transactional Computing (Transact), Houston, TX, USA (March 2013)Google Scholar
  19. 19.
    Avni, H., Dolev, S., Fatourou, P., Kosmas, E.: Abort free semanticTM by dependency aware scheduling of transactional instructions. In: Noubir, G., Raynal, M. (eds.) NETYS 2013. LNCS, vol. 8593, pp. 25–40. Springer, Heidelberg (2014)Google Scholar
  20. 20.
    Dragojevic, A., Guerraoui, R., Kapalka, M.: Stretching transactional memory. In: Proceedings of the 2009 ACM SIGPLAN Conference on Programming Language Design and Implementation (PLDI), pp. 155–165. ACM, New York (2009)CrossRefGoogle Scholar
  21. 21.
    Dziuma, D., Fatourou, P., Kanellou, E.: Consistency for transactional memory computing. Bulletin of European Association for Theoretical Computer Science (EATCS) 113, 112–135 (2014)MathSciNetGoogle Scholar
  22. 22.
    Ennals, R.: Cache sensitive software transactional memory. Tech. rep., Intel Research, Cambridge, United Kingdom (2005)Google Scholar
  23. 23.
    Ennals, R.: Software transactional memory should not be obstruction-free. Tech. Rep. IRC-TR–06–052, Intel Corporation (January 2006)Google Scholar
  24. 24.
    Felber, P., Fetzer, C., 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), pp. 237–246. ACM, New York (2008)Google Scholar
  25. 25.
    Fraser, K.: Practical lock freedom. Ph.D. thesis, Cambridge University Computer Laboratory (2003), also available as Technical Report UCAM-CL-TR-579Google Scholar
  26. 26.
    Gottschlich, J.E., Vachharajani, M., Siek, J.G.: An efficient software transactional memory using commit-time invalidation. In: Proceedings of the 8th Annual IEEE/ACM International Symposium on Code Generation and Optimization (CGO), pp. 101–110. IEEE Computer Society, ACM, New York (2010)Google Scholar
  27. 27.
    Guerraoui, R., Herlihy, M., Kapalka, M., Pochon, B.: Robust contention management in software transactional memory. In: Workshop on Synchronization and Concurrency in Object-Oriented Lanugages (SCOOL) (2005)Google Scholar
  28. 28.
    Guerraoui, R., Herlihy, M., Pochon, B.: Toward a theory of transactional contention managers. In: Proceedings of the 24th ACM Symposium on Principles of Distributed Computing (PODC), pp. 258–264. ACM, New York (2005)Google Scholar
  29. 29.
    Guerraoui, R., Kapalka, M.: On the correctness of transactional memory. In: Proceedings of the 13th ACM SIGPLAN Symposium on Principles and Practice of Parallel Programming (PPoPP), pp. 175–184. ACM, New York (2008)Google Scholar
  30. 30.
    Harris, T., Fraser, K.: Language support for lightweight transactions. SIGPLAN Not 38(11), 388–402 (2003)CrossRefGoogle Scholar
  31. 31.
    Harris, T., Larus, J., Rajwar, R.: Transactional Memory, 2nd edn. Morgan and Claypool Publishers (2010)Google Scholar
  32. 32.
    Harris, T., Plesko, M., Shinnar, A., Tarditi, D.: Optimizing memory transactions. In: Proceedings of the 2006 ACM SIGPLAN Conference on Programming Language Design and Implementation (PLDI), pp. 14–25. ACM, New York (2006)CrossRefGoogle Scholar
  33. 33.
    Herlihy, M., Luchangco, V., Moir, M., Scherer III, W.N.: Software transactional memory for dynamic-sized data structures. In: Proceedings of the 22nd ACM Symposium on Principles of Distributed Computing (PODC), pp. 92–101. ACM, New York (2003)Google Scholar
  34. 34.
    Herlihy, M., Moss, J.E.B.: Transactional memory: architectural support for lock-free data structures. SIGARCH Comput. Archit. News 21, 289–300 (1993)CrossRefGoogle Scholar
  35. 35.
    Hudson, R.L., Saha, B., Adl-Tabatabai, A.R., Hertzberg, B.C.: Mcrt-malloc: A scalable transactional memory allocator. In: Proceedings of the 5th International Symposium on Memory Management (ISMM), pp. 74–83. ACM, New York (2006)Google Scholar
  36. 36.
    Imbs, D., Raynal, M.: Virtual world consistency: A condition for stm systems (with a versatile protocol with invisible read operations). Theor. Comput. Sci. 444, 113–127 (2012)MathSciNetCrossRefzbMATHGoogle Scholar
  37. 37.
    Kosmas, E.: Software Transactional Memory. Master’s thesis, University of Ioannina (October 2008) (in Greek)Google Scholar
  38. 38.
    Marathe, V.J., Scherer III, W.N., Scott, M.L.: Design tradeoffs in modern software transactional memory systems. In: Proceedings of the 7th Workshop on Workshop on Languages, Compilers, and Run-time Support for Scalable Systems (LCR), pp. 1–7. ACM, New York (2004)CrossRefGoogle Scholar
  39. 39.
    Marathe, V.J., Scherer III, W.N., Scott, M.L.: Adaptive software transactional memory. In: Fraigniaud, P. (ed.) DISC 2005. LNCS, vol. 3724, pp. 354–368. Springer, Heidelberg (2005)CrossRefGoogle Scholar
  40. 40.
    Marathe, V.J., Spear, M.F., Heriot, C., Acharya, A., Eisenstat, D., Scherer III, W.N., Scott, M.L.: Lowering the overhead of nonblocking software transactional memory. Tech. Rep. 893, Department of Computer Science, University of Rochester (May 2006)Google Scholar
  41. 41.
    Marathe, V.J., Spear, M.F., Scott, M.L.: Scalable techniques for transparent privatization in software transactional memory. In: Proceedings of the 37th International Conference on Parallel Processing (ICPP), pp. 67–74. IEEE Computer Society (2008)Google Scholar
  42. 42.
    Marathe, V.J., Moir, M.: Toward high performance nonblocking software transactional memory. In: Proceedings of the 13th ACM SIGPLAN Symposium on Principles and Practice of Parallel Programming (PPoPP), pp. 227–236. ACM, New York (2008)Google Scholar
  43. 43.
    Martin, M.M.K., Blundell, C., Lewis, E.: Subtleties of transactional memory atomicity semantics. Computer Architecture Letters 5(2) (2006)Google Scholar
  44. 44.
    Matveev, A., Shavit, N.: Towards a fully pessimistic stm model. In: 7th ACM SIGPLAN Workshop on Transactional Computing (Transact), New Orleans, LA, USA (February 2012)Google Scholar
  45. 45.
    Minh, C.C., Trautmann, M., Chung, J., McDonald, A., Bronson, N., Casper, J., Kozyrakis, C., Olukotun, K.: An effective hybrid transactional memory system with strong isolation guarantees. In: Proceedings of the 34th Annual International Symposium on Computer Architecture (ISCA), pp. 69–80. ACM, New York (2007)Google Scholar
  46. 46.
    Moss, J.E.B., Hosking, A.L.: Nested transactional memory: Model and architecture sketches. Sci. Comput. Program. 63(2), 186–201 (2006), http://dx.doi.org/10.1016/j.scico.2006.05.010MathSciNetCrossRefzbMATHGoogle Scholar
  47. 47.
    Ni, Y., Welc, A., Adl-Tabatabai, A., 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: Proceedings of the 23rd Annual ACM SIGPLAN Conference on Object-Oriented Programming, Systems, Languages, and Applications (OOPSLA), pp. 195–212. ACM, New York (2008)Google Scholar
  48. 48.
    Olszewski, M., Cutler, J., Steffan, J.G.: Judostm: A dynamic binary-rewriting approach to software transactional memory. In: Proceedings of the 16th International Conference on Parallel Architecture and Compilation Techniques (PACT), pp. 365–375. IEEE Computer Society, Washington, DC (2007)CrossRefGoogle Scholar
  49. 49.
    Papadimitriou, C.H.: The serializability of concurrent database updates. J. ACM 26, 631–653 (1979)MathSciNetCrossRefzbMATHGoogle Scholar
  50. 50.
    Riegel, T.: Snapshot isolation for software transactional memory. In: 1st ACM SIGPLAN Workshop on Transactional Computing (Transact), Ottawa, Canada (March 2006)Google Scholar
  51. 51.
    Riegel, T., Felber, P., Fetzer, C.: A lazy snapshot algorithm with eager validation. In: Dolev, S. (ed.) DISC 2006. LNCS, vol. 4167, pp. 284–298. Springer, Heidelberg (2006)CrossRefGoogle Scholar
  52. 52.
    Riegel, T., Fetzer, C., Felber, P.: Time-based transactional memory with scalable time bases. In: Proceedings of the 19th ACM Symposium on Parallel Algorithms and Architectures (SPAA), pp. 221–228. ACM, New York (2007)Google Scholar
  53. 53.
    Riegel, T., Fetzer, C., Felber, P.: Automatic data partitioning in software transactional memories. In: Proceedings of the 20th ACM Symposium on Parallelism in Algorithms and Architectures (SPAA), pp. 152–159. ACM, New York (2008)Google Scholar
  54. 54.
    Romano, P., Carvalho, N., Rodrigues, L.: Towards distributed software transactional memory systems. In: Proceedings of the 2nd Workshop on Large-Scale Distributed Systems and Middleware (LADIS), pp. 4:1–4:4. ACM, New York (2008)Google Scholar
  55. 55.
    Scherer III, W.N., Scott, M.L.: Advanced contention management for dynamic software transactional memory. In: Proceedings of the 24th ACM Symposium on Principles of Distributed Computing (PODC), pp. 240–248. ACM, New York (2005)Google Scholar
  56. 56.
    Scott, M.L., Spear, M.F., Dalessandro, L., Marathe, V.J.: Transactions and privatization in delaunay triangulation. In: Proceedings of the 26th ACM Symposium on Principles of Distributed Computing (PODC), pp. 336–337. ACM, New York (2007)Google Scholar
  57. 57.
    Shavit, N., Touitou, D.: Software transactional memory. In: Proceedings of the 14th ACM Symposium on Principles of Distributed Computing (PODC), pp. 204–213. ACM, New York (1995)Google Scholar
  58. 58.
    Spear, M.F., Dalessandro, L., Marathe, V.J., Scott, M.L.: A comprehensive strategy for contention management in software transactional memory. In: Proceedings of the 14th ACM SIGPLAN Symposium on Principles and Practice of Parallel Programming (PPoPP), pp. 141–150. ACM, New York (2009)Google Scholar
  59. 59.
    Spear, M.F., Marathe, V.J., Dalessandro, L., Scott, M.L.: Privatization techniques for software transactional memory. In: Proceedings of the 26th ACM Symposium on Principles of Distributed Computing (PODC), pp. 338–339. ACM, New York (2007)Google Scholar
  60. 60.
    Spear, M.F., Michael, M., Scott, M.L.: Inevitability mechanisms for software transactional memory. In: 3rd ACM SIGPLAN Workshop on Transactional Computing (Transact), Salt Lake City, Utah, USA (February 2008)Google Scholar
  61. 61.
    Spear, M.F., Michael, M.M., von Praun, C.: Ringstm: scalable transactions with a single atomic instruction. In: Proceedings of the 20th ACM Symposium on Parallelism in Algorithms and Architectures (SPAA), pp. 275–284. ACM, New York (2008)Google Scholar
  62. 62.
    Spear, M.F., Dalessandro, L., Marathe, V.J., Scott, M.L.: Ordering-based semantics for software transactional memory. In: Baker, T.P., Bui, A., Tixeuil, S. (eds.) OPODIS 2008. LNCS, vol. 5401, pp. 275–294. Springer, Heidelberg (2008)CrossRefGoogle Scholar
  63. 63.
    Tabba, F., Moir, M., Goodman, J.R., Hay, A.W., Wang, C.: Nztm: Nonblocking zero-indirection transactional memory. In: Proceedings of the 21st ACM Symposium on Parallelism in Algorithms and Architectures (SPAA), pp. 204–213. ACM, New York (2009)Google Scholar
  64. 64.
    Wang, C., Chen, W.Y., Wu, Y., Saha, B., Adl-Tabatabai, A.R.: Code generation and optimization for transactional memory constructs in an unmanaged language. In: Proceedings of the 5th Annual IEEE/ACM International Symposium on Code Generation and Optimization (CGO), pp. 34–48. IEEE Computer Society, ACM, New York, USA (2007)CrossRefGoogle Scholar
  65. 65.
    Welc, A., Saha, B., Adl-Tabatabai, A.R.: Irrevocable transactions and their applications. In: Proceedings of the 20th ACM Symposium on Parallelism in Algorithms and Architectures (SPAA), pp. 285–296. ACM, New York (2008)Google Scholar

Copyright information

© Springer International Publishing Switzerland 2015

Authors and Affiliations

  • Panagiota Fatourou
    • 1
  • Mykhailo Iaremko
    • 2
  • Eleni Kanellou
    • 2
    • 3
  • Eleftherios Kosmas
    • 1
  1. 1.FORTH ICS & University of CreteHeraklion (Crete)Greece
  2. 2.FORTH ICSHeraklion (Crete)Greece
  3. 3.University of Rennes 1RennesFrance

Personalised recommendations