 
Summary: Nonatomic Mutual Exclusion with Local Spinning
(Extended Abstract)
James H. Anderson and YongJik Kim
Department of Computer Science
University of North Carolina at Chapel Hill
{anderson, kimy}@cs.unc.edu
ABSTRACT
We present an Nprocess localspin mutual exclusion algorithm, based on nonatomic reads and writes, in which each process
performs (log N) remote memory references to enter and exit its critical section. This algorithm is derived from Yang and
Anderson's atomic treebased localspin algorithm in a way that preserves its time complexity. No atomic read/write algorithm
with better asymptotic worstcase time complexity (under the remotememoryreferences measure) is currently known. This
suggests that atomic memory is not fundamentally required if one is interested in worstcase time complexity.
The same cannot be said if one is interested in fastpath algorithms (in which contentionfree time complexity is required
to be O(1)) or adaptive algorithms (in which time complexity is required to be proportional to the number of contend
ing processes). We show that such algorithms fundamentally require memory accesses to be atomic. In particular, we
show that for any Nprocess nonatomic algorithm, there exists a singleprocess execution in which the lone competing pro
cess executes (log N/ log log N) remote operations to enter its critical section. Moreover, these operations must access
( log N/ log log N) distinct variables, which implies that fast and adaptive algorithms are impossible even if caching tech
niques are used to avoid accessing the processorstomemory interconnection network.
Work supported by NSF grants CCR 9972211, CCR 9988327, and ITR 0082866.
