A Competitive Analysis for Balanced Transactional Memory Workloads

We consider transactional memory contention management in the context of balanced workloads, where if a transaction is writing, the number of write operations it performs is a constant fraction of its total reads and writes. We explore the theoretical performance boundaries of contention management in balanced workloads from the worstcase perspective by presenting and analyzing two new polynomial time contention management algorithms. The first algorithm Clairvoyant is O(√s)-competitive, where s is the number of shared resources. This algorithm depends on explicitly knowing the conflict graph. The second algorithm Non-Clairvoyant is O(√s) ċ log n)-competitive, with high probability, which is only a O(log n) factor worse, but does not require knowledge of the conflict graph, where n is the number of transactions. Both of these algorithms are greedy. We also prove that the performance of Clairvoyant is tight, since there is no polynomial time contention management algorithm that is better than O((√s)1-e)-competitive for any constant e > 0, unless NP⊆ZPP. To our knowledge, these results are significant improvements over the best previously known O(s) competitive ratio bound.

[1]  Maurice Herlihy,et al.  Robust Contention Management in Software Transactional Memory , 2005, OOPSLA 2005.

[2]  Gokarna Sharma,et al.  On the Performance of Window-Based Contention Managers for Transactional Memory , 2011, 2011 IEEE International Symposium on Parallel and Distributed Processing Workshops and Phd Forum.

[3]  Rajeev Motwani,et al.  Non-clairvoyant scheduling , 1994, SODA '93.

[4]  Subhash Khot,et al.  Improved inapproximability results for MaxClique, chromatic number and approximate graph coloring , 2001, Proceedings 2001 IEEE International Conference on Cluster Computing.

[5]  Hsien-Hsin S. Lee,et al.  Adaptive transaction scheduling for transactional memory systems , 2008, SPAA '08.

[6]  Kunle Olukotun,et al.  STAMP: Stanford Transactional Applications for Multi-Processing , 2008, 2008 IEEE International Symposium on Workload Characterization.

[7]  Edward G. Coffman,et al.  Mutual Exclusion Scheduling , 1996, Theor. Comput. Sci..

[8]  Roger Wattenhofer,et al.  Bounds on Contention Management Algorithms , 2009, ISAAC.

[9]  William Pugh,et al.  Skip Lists: A Probabilistic Alternative to Balanced Trees , 1989, WADS.

[10]  Rachid Guerraoui,et al.  Toward a theory of transactional contention managers , 2005, PODC '05.

[11]  Simon L. Peyton Jones,et al.  Composable memory transactions , 2005, CACM.

[12]  Hagit Attiya,et al.  Transactional Contention Management as a Non-Clairvoyant Scheduling Problem , 2010, Algorithmica.

[13]  Klaus Jansen,et al.  Restrictions of Graph Partition Problems. Part I , 1995, Theor. Comput. Sci..

[14]  Mikel Luján,et al.  Steal-on-Abort: Improving Transactional Memory Performance through Dynamic Transaction Reordering , 2008, HiPEAC.

[15]  Nir Shavit,et al.  Transactional Locking II , 2006, DISC.

[16]  David Eisenstat,et al.  Lowering the Overhead of Software Transactional Memory , 2006 .

[17]  Dana Ron,et al.  Scheduling with conflicts: online and offline algorithms , 2009, J. Sched..

[18]  Gokarna Sharma,et al.  A Competitive Analysis for Balanced Transactional Memory Workloads , 2010, Algorithmica.

[19]  William N. Scherer,et al.  Advanced contention management for dynamic software transactional memory , 2005, PODC '05.

[20]  Donald E. Porter,et al.  MetaTM/TxLinux: Transactional Memory for an Operating System , 2007, IEEE Micro.

[21]  Keir Fraser,et al.  Language support for lightweight transactions , 2003, SIGP.

[22]  Guy Kortsarz,et al.  Multicoloring trees , 2003, Inf. Comput..

[23]  David S. Johnson,et al.  Computers and Intractability: A Guide to the Theory of NP-Completeness , 1978 .

[24]  Hagit Attiya,et al.  Local Labeling and Resource Allocation Using Preprocessing , 1994, WDAG.

[25]  Rachid Guerraoui,et al.  Polymorphic Contention Management , 2005, DISC.

[26]  Dorit S. Hochba,et al.  Approximation Algorithms for NP-Hard Problems , 1997, SIGA.

[27]  Maurice Herlihy,et al.  Obstruction-free synchronization: double-ended queues as an example , 2003, 23rd International Conference on Distributed Computing Systems, 2003. Proceedings..

[28]  Uriel Feige,et al.  Zero Knowledge and the Chromatic Number , 1998, J. Comput. Syst. Sci..

[29]  Torvald Riegel,et al.  Dynamic performance tuning of word-based software transactional memory , 2008, PPoPP.

[30]  Gokarna Sharma,et al.  Window-Based Greedy Contention Management for Transactional Memory , 2010, DISC.

[31]  Nir Shavit,et al.  Software transactional memory , 1995, PODC '95.

[32]  Hagit Attiya The inherent complexity of transactional memory and what to do about it , 2010, PODC '10.

[33]  Rachid Guerraoui,et al.  Preventing versus curing: avoiding conflicts in transactional memories , 2009, PODC '09.

[34]  David Hasenfratz,et al.  Transactional Memory: How to perform load adaption in a simple and distributed manner , 2010, 2010 International Conference on High Performance Computing & Simulation.

[35]  Maurice Herlihy,et al.  Software transactional memory for dynamic-sized data structures , 2003, PODC '03.

[36]  Hagit Attiya,et al.  Transactional Scheduling for Read-Dominated Workloads , 2009, OPODIS.

[37]  Ronald L. Graham,et al.  Bounds for Multiprocessor Scheduling with Resource Constraints , 1975, SIAM J. Comput..

[38]  Michael E. Saks,et al.  A dining philosophers algorithm with polynomial response time , 1990, Proceedings [1990] 31st Annual Symposium on Foundations of Computer Science.

[39]  Danny Hendler,et al.  CAR-STM: scheduling-based collision avoidance and resolution for software transactional memory , 2008, PODC '08.

[40]  Sandy Irani,et al.  Scheduling with conflicts, and applications to traffic signal control , 1996, SODA '96.

[41]  Jan Vitek,et al.  STMBench7: a benchmark for software transactional memory , 2007, EuroSys '07.

[42]  Maurice Herlihy,et al.  Transactional Memory: Architectural Support For Lock-free Data Structures , 1993, Proceedings of the 20th Annual International Symposium on Computer Architecture.

[43]  Mikel Luján,et al.  On the Performance of Contention Managers for Complex Transactional Memory Benchmarks , 2009, 2009 Eighth International Symposium on Parallel and Distributed Computing.