Nonblocking algorithm for shared queues using compare-and-swap

Sundeep Prakash, Yann-Hang Lee, Theodore Johnson

Research output: Contribution to journalArticle

44 Citations (Scopus)

Abstract

Nonblocking algorithms for concurrent objects guarantee that an object is always accessible, in contrast to blocking algorithms in which a slow or halted process can render part or all of the data structure inaccessible to other processes. A number of algorithms have been proposed for shared FIFO queues, but nonblocking implementations are few and either limit the concurrency or provide inefficient solutions. In this paper we present a simple and efficient nonblocking shared FIFO queue algorithm with O(n) system latency, no additional memory requirements, and enqueuing and dequeuing times independent of the size of the queue. We use the compare-&-swap operation as the basic synchronization primitive. We model our algorithm analytically and with a simulation, and compare its performance with that of a blocking FIFO queue. We find that the nonblocking queue has better performance if processors are occasionally slow, but worse performance if some processors are always slower than others.

Original languageEnglish (US)
Pages (from-to)548-559
Number of pages12
JournalIEEE Transactions on Computers
Volume43
Issue number5
DOIs
StatePublished - May 1994
Externally publishedYes

Fingerprint

Swap
Queue
Concurrency
Data structures
Latency
Concurrent
Data Structures
Synchronization
Data storage equipment
Requirements
Simulation
Object

ASJC Scopus subject areas

  • Hardware and Architecture
  • Electrical and Electronic Engineering

Cite this

Nonblocking algorithm for shared queues using compare-and-swap. / Prakash, Sundeep; Lee, Yann-Hang; Johnson, Theodore.

In: IEEE Transactions on Computers, Vol. 43, No. 5, 05.1994, p. 548-559.

Research output: Contribution to journalArticle

Prakash, Sundeep ; Lee, Yann-Hang ; Johnson, Theodore. / Nonblocking algorithm for shared queues using compare-and-swap. In: IEEE Transactions on Computers. 1994 ; Vol. 43, No. 5. pp. 548-559.
@article{6dff31389bb84fc78494172c880721cc,
title = "Nonblocking algorithm for shared queues using compare-and-swap",
abstract = "Nonblocking algorithms for concurrent objects guarantee that an object is always accessible, in contrast to blocking algorithms in which a slow or halted process can render part or all of the data structure inaccessible to other processes. A number of algorithms have been proposed for shared FIFO queues, but nonblocking implementations are few and either limit the concurrency or provide inefficient solutions. In this paper we present a simple and efficient nonblocking shared FIFO queue algorithm with O(n) system latency, no additional memory requirements, and enqueuing and dequeuing times independent of the size of the queue. We use the compare-&-swap operation as the basic synchronization primitive. We model our algorithm analytically and with a simulation, and compare its performance with that of a blocking FIFO queue. We find that the nonblocking queue has better performance if processors are occasionally slow, but worse performance if some processors are always slower than others.",
author = "Sundeep Prakash and Yann-Hang Lee and Theodore Johnson",
year = "1994",
month = "5",
doi = "10.1109/12.280802",
language = "English (US)",
volume = "43",
pages = "548--559",
journal = "IEEE Transactions on Computers",
issn = "0018-9340",
publisher = "IEEE Computer Society",
number = "5",

}

TY - JOUR

T1 - Nonblocking algorithm for shared queues using compare-and-swap

AU - Prakash, Sundeep

AU - Lee, Yann-Hang

AU - Johnson, Theodore

PY - 1994/5

Y1 - 1994/5

N2 - Nonblocking algorithms for concurrent objects guarantee that an object is always accessible, in contrast to blocking algorithms in which a slow or halted process can render part or all of the data structure inaccessible to other processes. A number of algorithms have been proposed for shared FIFO queues, but nonblocking implementations are few and either limit the concurrency or provide inefficient solutions. In this paper we present a simple and efficient nonblocking shared FIFO queue algorithm with O(n) system latency, no additional memory requirements, and enqueuing and dequeuing times independent of the size of the queue. We use the compare-&-swap operation as the basic synchronization primitive. We model our algorithm analytically and with a simulation, and compare its performance with that of a blocking FIFO queue. We find that the nonblocking queue has better performance if processors are occasionally slow, but worse performance if some processors are always slower than others.

AB - Nonblocking algorithms for concurrent objects guarantee that an object is always accessible, in contrast to blocking algorithms in which a slow or halted process can render part or all of the data structure inaccessible to other processes. A number of algorithms have been proposed for shared FIFO queues, but nonblocking implementations are few and either limit the concurrency or provide inefficient solutions. In this paper we present a simple and efficient nonblocking shared FIFO queue algorithm with O(n) system latency, no additional memory requirements, and enqueuing and dequeuing times independent of the size of the queue. We use the compare-&-swap operation as the basic synchronization primitive. We model our algorithm analytically and with a simulation, and compare its performance with that of a blocking FIFO queue. We find that the nonblocking queue has better performance if processors are occasionally slow, but worse performance if some processors are always slower than others.

UR - http://www.scopus.com/inward/record.url?scp=0028436588&partnerID=8YFLogxK

UR - http://www.scopus.com/inward/citedby.url?scp=0028436588&partnerID=8YFLogxK

U2 - 10.1109/12.280802

DO - 10.1109/12.280802

M3 - Article

AN - SCOPUS:0028436588

VL - 43

SP - 548

EP - 559

JO - IEEE Transactions on Computers

JF - IEEE Transactions on Computers

SN - 0018-9340

IS - 5

ER -