### Some Complexity Results in the Design of Deadlock-Free Packet Switching Networks

Sam Toueg, Kenneth Steiglitz
1981 SIAM journal on computing (Print)
Deadlocks are very serious system failures and have been observed in existing packet switching networks (PSN's). Several problems related to the design of deadlock-free PSN's are investigated here. Polynomial-time algorithms are given for some of these problems, but most of them are shown to be NP-complete or NP-hard, and therefore polynomial-time algorithms are not likely to be found. 1. Basic definitions. A packet switching network (or PSN) is a directed graph G (V, E); the vertices V
more » ... t processors, and the edges E represent communication links. We assume messages, called packets, are to be passed between processors. Each vertex vi has an associated constant bi, the number of buffers at this vertex; a buffer can hold exactly one packet. Associated with each packet is an acyclic route /-)1, V2," Vq, which is a path in G. Vertex /)1 is the source, and vq is the destination vertex for the packet. We assume a fixed routing procedure [KL], where a packet's route is determined at the source node. We may also assume that the route of a packet is included as part of the message in the packet, although in practice the packet could hold only the source and destination, with each processor in the network responsible for deducing the next vertex to which the packet is to be passed. The moves made by the network are of three types: 1. Generation. A vertex v creates a packet which is placed in an empty buffer of v. 2. Passing. A vertex v transfers a packet in one of its buffers to an empty buffer of vertex w, where vw is an edge, and the route for the packet has w following v. The buffer of v holding the packet becomes empty. Consumption. A packet in a buffer of v, such that the destination for the packet is v, is removed from that buffer and the buffer is made empty. 2. Flow control procedures. A flow control procedure (or controller) for a network is an algorithm that permits or forbids various moves in the network. One of the key problems in packet switching is preventing deadlock states, which are situations in which one or more packets can never make a move. Deadlock states have been observed in existing packet switching networks [KL]; they tend to occur under near-saturation input load [GHKP]. For example, in the network of Fig. 1 , if all physically possible moves are permitted by the controller, vl generates bl packets with destination re, v2 .generates be packets with destination v3, and v3 generates b3 packets with destination Vl, then all buffers of all vertices will be full, no consumption moves can take place without a pass move, and no generation can take place. It is not hard to see that the network is deadlocked.