Contention-Sensitive Data Structures and Algorithms

A contention-sensitive data structure is a concurrent data structure in which the overhead introduced by locking is eliminated in the common cases, when there is no contention, or when processes with non-interfering operations access it concurrently. When a process invokes an operation on a contentionsensitive data structure, in the absence of contention or interference, the process must be able to complete its operation in a small number of steps and without using locks. Using locks is permitted only when there is interference. We formally define the notion of contention-sensitive data structures, propose four general transformations that facilitate devising such data structures, and illustrate the benefits of the approach by implementing a contention-sensitive consensus algorithm, a contention-sensitive double-ended queue data structure, and a contention-sensitive election algorithm. Finally, we generalize the result to enable to avoid locking also when contention is low.

[1]  Nancy A. Lynch,et al.  Impossibility of distributed consensus with one faulty process , 1985, JACM.

[2]  Rachid Guerraoui,et al.  The weakest failure detectors to boost obstruction-freedom , 2006, Distributed Computing.

[3]  H. T. Kung,et al.  Concurrent manipulation of binary search trees , 1980, TODS.

[4]  Paul E. McKenney Memory ordering in modern microprocessors, Part I , 2005 .

[5]  Rudolf Bayer,et al.  Concurrency of operations on B-trees , 1994, Acta Informatica.

[6]  Gadi Taubenfeld,et al.  Possibility and impossibility results in a shared memory environment , 1989, Acta Informatica.

[7]  Carla Schlatter Ellis,et al.  Extendible hashing for concurrent operations and distributed data , 1983, PODS '83.

[8]  Leslie Lamport,et al.  A fast mutual exclusion algorithm , 1987, TOCS.

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

[10]  Michel Raynal,et al.  Algorithms for mutual exclusion , 1986 .

[11]  S. B. Yao,et al.  Efficient locking for concurrent operations on B-trees , 1981, TODS.

[12]  G. Taubenfeld,et al.  Results about fast mutual exclusion , 1992, [1992] Proceedings Real-Time Systems Symposium.

[13]  Mark Moir,et al.  Obstruction-Free Algorithms Can Be Practically Wait-Free , 2005, DISC.

[14]  Michael Merritt,et al.  Resilient Consensus for Infinitely Many Processes , 2003, DISC.

[15]  Jonathan Walpole,et al.  Why the grass may not be greener on the other side: a comparison of locking vs. transactional memory , 2007, OPSR.

[16]  William B. Easton Process synchronization without long-term interlock , 1971, SOSP '71.

[17]  Eric Ruppert,et al.  Lock-free linked lists and skip lists , 2004, PODC '04.

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

[19]  Maurice Herlihy,et al.  Wait-free synchronization , 1991, TOPL.

[20]  Leslie Lamport,et al.  How to Make a Multiprocessor Computer That Correctly Executes Multiprocess Programs , 2016, IEEE Transactions on Computers.

[21]  Shlomo Moran,et al.  Extended Impossibility Results for Asynchronous Complete Networks , 1987, Inf. Process. Lett..

[22]  Gadi Taubenfeld Efficient Transformations of Obstruction-Free Algorithms into Non-blocking Algorithms , 2007, DISC.

[23]  Marcos K. Aguilera,et al.  Timeliness-based wait-freedom: a gracefully degrading progress condition , 2008, PODC '08.

[24]  John D. Valois Implementing Lock-Free Queues , 1994 .

[25]  Edsger W. Dijkstra,et al.  Solution of a problem in concurrent programming control , 1965, CACM.

[26]  Jonathan Walpole,et al.  Why the grass may not be greener on the other side: a comparison of locking vs. transactional memory , 2010, OPSR.

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

[28]  Philippas Tsigas,et al.  Lock-Free and Practical Deques using Single-Word Compare-And-Swap , 2004, ArXiv.

[29]  Mark Moir,et al.  On the Uncontended Complexity of Consensus , 2003, DISC.

[30]  Calton Pu,et al.  A Lock-Free Multiprocessor OS Kernel , 1992, OPSR.

[31]  Paul E. McKenney,et al.  Making lockless synchronization fast: performance implications of memory reclamation , 2006, Proceedings 20th IEEE International Parallel & Distributed Processing Symposium.

[32]  Rachid Guerraoui,et al.  Computing with Reads and Writes in the Absence of Step Contention , 2005, DISC.

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

[34]  Sarita V. Adve,et al.  Shared Memory Consistency Models: A Tutorial , 1996, Computer.

[35]  Timothy L. Harris,et al.  A Pragmatic Implementation of Non-blocking Linked-Lists , 2001, DISC.

[36]  Philippas Tsigas,et al.  Lock-Free and Practical Doubly Linked List-Based Deques Using Single-Word Compare-and-Swap , 2004, OPODIS.

[37]  Gadi Taubenfeld Synchronization Algorithms and Concurrent Programming , 2006 .

[38]  Maurice Herlihy,et al.  Linearizability: a correctness condition for concurrent objects , 1990, TOPL.

[39]  Mark Moir,et al.  Wait-Free Algorithms for Fast, Long-Lived Renaming , 1995, Sci. Comput. Program..

[40]  Maged M. Michael,et al.  Simple, fast, and practical non-blocking and blocking concurrent queue algorithms , 1996, PODC '96.

[41]  Ravi Rajwar,et al.  Speculative lock elision: enabling highly concurrent multithreaded execution , 2001, Proceedings. 34th ACM/IEEE International Symposium on Microarchitecture. MICRO-34.

[42]  Michael Merritt,et al.  Computing with Infinitely Many Processes , 2000, DISC.