Editor An Optimal Algorithm for Mutual Exclusion in Computer Networks

Abstract

An algorithm is proposed that creates mutual exclu-sion in a computer network whose nodes communicate only by messages and do not share memory. The algo-rithm sends only 2*(N- 1) messages, where N is the number of nodes in the network per critical section invocation. This number of messages is at a minimum if parallel, distributed, symmetric control is used; hence, the algorithm is optimal in this respect. The time needed to achieve mutual exclusion is also minimal under some general assumptions. As in Lamport's "bakery algorithm, " unbounded se-quence numbers are used to provide first-come first-served priority into the critical section. It is shown that the number can be contained in a fixed amount of memory by storing it as the residue of a modulus. The number of messages required to implement the exclusion can be reduced by using sequential node-by-node processing, by using broadcast message techniques, or by sending infor-mation through timing channels. The "readers and writers " problem is solved by a simple modification of the algorithm and the modifications necessary to make the algorithm robust are described. Key Words and Phrases: concurrent programming, critical section, distributed algorithm, mutual exclusion

    Similar works

    Full text

    thumbnail-image

    Available Versions