We present a linearizable, non-blocking @math -ary search tree ( @math -ST) that supports fast searches and range queries. Our algorithm uses single-word compare-and-swap (CAS) operations, and tolerates any number of crash failures. Performance experiments show that, for workloads containing small range queries, our @math -ST significantly outperforms other algorithms which support these operations, and rivals the performance of a leading concurrent skip-list, which provides range queries that cannot always be linearized.
Snapshots offer another approach for implementing range queries. If we could quickly take a snapshot of the data structure, then we could simply perform a sequential range query on the result. The snapshot object is a vector @math of data elements supporting two operations: Update @math , which atomically sets @math to @math , and Scan , which atomically reads and returns all of the elements of @math . Scan can be implemented by repeatedly performing a pair of Collect s (which read each element of @math in sequence and return a new vector containing the values it read) until the results of the two Collect s are equal @cite_3 . Attiya, et al. @cite_14 introduced , offering a modified Scan @math operation which operates on a subset of the elements of @math . Their construction requires both CAS and fetch-and-add.
@cite_14 @cite_3
2167680229 1538367796 2095126777 1993805917
We introduce a generalization of the atomic snapshot object, which we call the partial snapshot object. This object stores a vector of values. Processes may write components of the vector individually or atomically read any subset of the components. We investigate implementations of the latter partial scan operation that are more efficient than the complete scans of traditional snapshot objects. We present an algorithm that is based on a new implementation of the active set abstraction, which may be of independent interest. In the Iterated Immediate Snapshotmodel ( @math ) the memory consists of a sequence of one-shot Immediate Snapshot( @math ) objects. Processes access the sequence of @math objects, one-by-one, asynchronously, in a wait-freemanner; any number of processes can crash. Its interest lies in the elegant recursive structure of its runs, hence of the ease to analyze it round by round. In a very interesting way, Borowsky and Gafni have shown that the @math model and the read write model are equivalent for the wait-free solvability of decision tasks. This paper extends the benefits of the @math model to partially synchronous systems. Given a shared memory model enriched with a failure detector, what is an equivalent @math model? The paper shows that an elegant way of capturing the power of a failure detector and other partially synchronous systems in the @math model is by restricting appropriately its set of runs, giving rise to the Iterated Restricted Immediate Snapshotmodel ( @math ). The snapshot object is an important tool for constructing wait-free asynchronous algorithms. We relate the snapshot object to the lattice agreement decision problem. It is shown that any algorithm for solving lattice agreement can be transformed into an implementation of a snapshot object. The overhead cost of this transformation is only a linear number of read and write operations on atomic single-writer multi-reader registers. The transformation uses an unbounded amount of shared memory. We present a deterministic algorithm for lattice agreement that used O(log2 n) operations on 2-processor Test & Set registers, plus O(n) operations on atomic single-writer multi-reader registers. The shared objects are used by the algorithm in a dynamic mode, that is, the identity of the processors that access each of the shared objects is determined dynamically during the execution of the algorithm. By a randomized implementation of 2-processors Test & Set registers from atomic registers, this algorithm implies a randomized algorithm for lattice agreement that uses an expected number of O(n) operations on (dynamic) atomic single-writer multi-reader registers. Combined with our transformation this yields implementations of atomic snapshots with the same complexity. This paper introduces a general formulation of atomic snapshot memory , a sharedmemory partitioned into words written( updated ) by individual processes, orinstantaneously read ( scanned ) in itsentirety. This paper presents three wait-free implementations of atomicsnapshot memory. The first implementation in this paper uses unbounded(integer) fields in these registers, and is particularly easy tounderstand. The second implementation uses bounded registers. Itscorrectness proof follows the ideas of the unbounded implementation.Both constructions implement a single-writer snapshot memory, in whicheach word may be updated by only one process, from single-writer, n -reader registers. The thirdalgorithm implements a multi-writer snapshot memory from atomic n -writer, n -reader registers, again echoing keyideas from the earlier constructions. All operations requireT( n 2 ) readsand writes to the component shared registers in the worst case. — Authors' Abstract