tight bounds on the round complexity of distributed 1 ... - CS, Technion

0 downloads 0 Views 99KB Size Report
[MW] a class of tasks was shown not to be solvable in the presence of one faulty ... eral case, the round complexity of T is not a constant, but a function of the ...
TIGHT BOUNDS ON THE ROUND COMPLEXITY OF DISTRIBUTED 1-SOLVABLE TASKS1 Ofer Biran Science and Technology, IBM Israel MATAM, Haifa, Israel 31905 Shlomo Moran and Shmuel Zaks Department of Computer Science Technion, Haifa, Israel 32000

ABSTRACT A distributed task T is 1-solvable if there exists a protocol that solves it in the presence of (at most) one crash failure. A precise characterization of the 1-solvable tasks was given in [BMZ]. In this paper we determine the number of rounds of communication that are required, in the worst case, by a protocol which 1-solves a given 1-solvable task T for n processors. We define the radius R (T) of T, and show that if R (T) is finite, then the number of rounds is Θ(logn R (T) ); more precisely, we give a lower bound of log(n −1) R (T), and an upper bound of 2+ log(n −1) R (T) . The upper bound implies, for example, that each of the following tasks: renaming, order preserving renaming ([ABDKPR]) and binary monotone consensus ([BMZ]) can be solved in the presence of one fault in 3 rounds of communications. All previous protocols that 1-solved these tasks required Ω(n) rounds. The result is also generalized to tasks whose radii are not bounded, e.g., the approximate consensus and its variants ([DLPSW , BMZ]).

 1 This research was supported in part by Technion V.P.R. Funds - Wellner Research Fund and Loewengart Research Fund, and by the Foundation for Research in Electronics, Computers and Communications, administrated by the Israel Academy of Sciences and Humanities, and by the ESPRIT II Basic Research Actions Program of the EC under contract no. 3075 (project ALCOM). A preliminary version of this paper appeared in the proceedings of the 4th International Workshop on Distributed Algorithms, Bari, Italy 1990.

1

1. INTRODUCTION An asynchronous distributed network consists of a set of processors, connected by communication lines, through which they communicate in order to accomplish a certain task; the time delay on the communication lines is finite, but unbounded and unpredictable. In this paper we study the case when at most one processor is faulty, which means that from some point on none of its messages is delivered (fail-stop failure). It was shown in [FLP] that it is impossible to achieve a distributed consensus for this case. This result was extended in several directions. In [DDS] the features of asynchrony that yield the result of [FLP] and related results were analyzed. The possibility of reaching agreement when restricting the pure asynchrony was studied also in [ADG,DLS]. In [DLPSW] it was shown that approximate consensus, in which all processors must agree on values that are arbitrarily close to one another, is possible in the presence of a constant fraction of faulty processors. In [ABDKPR] the solvability of two renaming problems (which will be defined later) in the presence of faults was investigated. In [MW] a class of tasks was shown not to be solvable in the presence of one faulty processor (not 1-solvable). In [BMZ] we provided a complete characterization of the 1-solvable tasks. Specifically, this characterization provides a halting procedure for deciding whether a given task, specified by its (finite) input/output relation, is 1-solvable. No such procedure is known for the case where t >1. A possible step towards this latter goal was done in three recent works [BG,HS,SZ], which relate the t-solvability of tasks (for arbitrary t) to properties of high dimensional simplicial complexes. In this paper we are interested in the round complexity of a 1-solvable task, which is the number of communication rounds that are required, in the worst case, by any protocol that 1solves it. This measure attempts to capture the notion of time complexity for asynchronous, fault tolerant protocols. In [Fe], a tight bound was given for the specific task of the approximate consensus. Results of the same type in other models were given in [ALS] for the approximate consensus task in asynchronous shared memory model, and in [HT] for the renaming task in synchronous message passing model. We provide optimal bounds (up to an additive constant) on the round complexity of a general 1-solvable task. We first consider bounded tasks, which are tasks that can be 1-solved by protocols that require at most a constant number of rounds in all possible executions (e.g., the renaming tasks and the strong binary monotone consensus task [ABDKPR, BMZ]). Then we generalize our results for unbounded tasks (like the approximate consensus and its variants [DLPSW , BMZ]). The outline of our proof is as follows: For a distributed task T, let XT be the set of possible input vectors for T. First we show, by using the result in [BMZ], that if T is 1-solvable, then there is a set RT of radius functions related to T, where each radius function ρ is a mapping →). We use this set to define x to a positive integer ρ(x ρ:XT →N, which maps each input vector → →). R (T), the radius of the task T, as R (T) = min sup ρ(x ρ∈RT → x ∈XT

In proving our bounds, we first consider only tasks T for which R (T) is finite, and show that these are exactly the bounded tasks. We show that if R (T) is finite then the round complexity of T is Θ(logn R (T) ); more precisely, we give a lower bound of log(n −1) R (T), and an

2

upper bound of 2+ log(n −1) R (T) . We then extend the results to an arbitrary task T. In the general case, the round complexity of T is not a constant, but a function of the input vector. Since there is no natural total order on these functions, we cannot define the optimal round complexity of T, but only define the set of minimal round complexity functions of T, in the natural partial ordering of functions. This set is defined by a correspondence to the set of minimal radius functions in RT . The upper bound implies, for example, that each of the following tasks: renaming with n +1 new names, order preserving renaming with 2n −1 new names ([ABDKPR]), and strong binary monotone consensus ([BMZ]) can be solved in the presence of one fault in three rounds of communications. All previous protocols that 1-solved these tasks required Ω(n) rounds (however, it is fair to note that the protocols for the renaming problems [ABDKPR] were designed to tolerate multiple failures). For the case where R (T) is infinite, we extend the optimal bounds of [Fe] for the approximate consensus: we show that similar bounds hold for variants of the approximate consensus that were studied in [BMZ], which are considerably harder than the (original) approximate consensus. The rest of the paper is organized as follows: In Section 2 we provide the preliminary definitions. In Section 3 we define standard protocols and round complexity. In Section 4 we define the radius of a task. The lower and upper bounds for bounded tasks are presented in Sections 5 and 6. In Section 7 we generalize our results for arbitrary tasks and in Section 8 we present some applications.

2. PRELIMINARY DEFINITIONS AND NOTATIONS 2.1 Asynchronous Systems An asynchronous distributed system is composed of a set P = {P 1 , P 2 , . . . , Pn } of n processors (n ≥ 3), each having a unique identity. We assume that the identities of the processors are mutually known, and w.l.o.g. that the identity of Pi is i. Our results are applicable also to the model in which the identities are not mutually known; the modification of the results to this model is done in a way similar to the one described in [BMZ]. The processors are connected by communication links, and they communicate by exchanging messages along them. Messages arrive with no error in a finite but unbounded and unpredictable time; however, one of the processors might be faulty, in which case messages might not have these properties (the exact definition is given in the sequel). 2.2 Decision Tasks Definition: Let X and D be sets of input values and decision values, respectively. A distributed decision task T is a function n

T : XT → 2D − {∅}, where XT ⊆ X n . XT is called the input set of the task T. DT , the decision set of the task T, is the →) over all → x ∈ XT . Each vector → x = (x 1 ,x 2 ,...,xn )∈XT is called an input union of the sets T (x vector, and it represents the initial assignment of the input value xi ∈X to processor Pi , for → i = 1,2,...,n. Each vector d = (d 1 ,d 2 ,...,dn )∈DT is called a decision vector, and it represents

3

the assignment of a decision value di ∈D to processor Pi , for i = 1,2,...,n. Thus, a decision task T maps each input vector to a non-empty set of allowable decision vectors. We assume that all tasks T discussed in this paper are computable, in the sense that the → → → →,d →)} is recursive. set {(x ) : x ∈XT and d ∈T (x Examples: (1)

(2)

(3)

(4) (5)

(6)

Consensus [FLP]: A consensus task is any task T where XT = X n for → an arbitrary set X, and such →) ⊆ {(0,0,...0),(1,1,...,1)} for every input vector → x ∈XT . Let 0 denote the vector (0,0,...,0), that → T (x task T, in which there and 1 denote the vector (1,1,...,1). A strong consensus → task is→a consensus → → exist two input vectors → u and → v such that T (u ) = {0} and T (v ) = {1}. The main result in [FLP] implies that a strong consensus task is not 1-solvable. Strong Binary Monotone Consensus [BMZ]: This is probably the strongest variant of the consensus task which is 1-solvable. To simplify the definition, assume that n is even: The input is an →) consists of all vectors → d = (d 1 , . . . ,dn ) where each di is integer vector → x = (x 1 , . . . ,xn ), and T (x one of the two medians of the multiset {x 1 , . . . ,xn }, and di ≤di +1 (the “strong” stands for the fact that the two values must be the medians). Renaming [ABDKPR]: This task is defined for a given integer K, where K ≥ n. The input set XT is →) is the set of all x, T (x the set of all vectors (x 1 , . . . ,xn ) of distinct integers. For a given input → → . . . ,dn ) satisfying 1 ≤ di ≤ K and such that for each i, j, di ≠ d j . In order to integer vectors d = (d 1 , prevent trivial solutions in which Pi always decides on i, this task assumes a model in which the processors identities are not known. Order Preserving Renaming (OPR) [ABDKPR]: This task is similar to the renaming task, with the additional requirement that for each i, j, xi < x j implies di < d j . Approximate Consensus [DLPSW]: This task is defined for any given ε > 0. The input set XT is →) is the set Q n , where Q is the→set of rational numbers, and for a given input → x = (x 1 , . . . ,xn ), T (x of all vectors d =(d 1 , . . . ,dn ) satisfying | di − d j | ≤ε and m≤di ≤M (1 ≤ i, j ≤ n), where m = min{x 1 , . . . ,xn } and M = max{x 1 , . . . ,xn }. Strong Binary Monotone Approximate Consensus [BMZ]: This is a harder variant of the approximate consensus task which is still 1-solvable. To simplify the definition, assume that n is →) even: The input is the same the approximate consensus. For an input → x = (x 1 , . . . ,xn ), T (x → as for → consists of all vectors d = (d 1 , . . . ,dn ) satisfying: d has at most two distinct entries, which lie between the two medians of the multiset {x 1 , . . . ,xn }, and di ≤ di +1 ≤ di + ε.

2.3. Protocols and Executions A protocol for a given network is a set of n programs, each associated with a single processor in the network. Each such program contains operations of sending a message to a neighbor, receiving a message and processing information in the local memory. The local processing includes a special operation called deciding, which the processor may execute only once; A processor decides by writing a decision value to a write-once register. If the network is initialized with the input vector → x ∈X n (i.e., the value xi is assigned to processor Pi ), and if each processor executes its own program in a given protocol α, then the sequence of operations performed by the processors is called an execution of α on input → x. (We assume here that no two operations occur simultaneously; otherwise, we order them arbitrarily. For more formal definitions see, e.g., [KMZ]. For the definition of the atomic step we adapt the model of [FLP].) → x if there is an exeDefinition: A vector d = (d 1 ,d 2 , . . . ,dn ) is an output vector of α on input → → . . . n. cution of α on x in which processor Pi decides on di , for i = 1

4

2.4. Faults and 1-Solvability Definition: A processor P is faulty in an execution e if it stops participating in the protocol prematurely (a fail-stop failure; see, e.g., [FLP]. Also known as crash failure; see, e.g., [NT]). A processor is non-faulty otherwise. Definition: A protocol α 1-solves a task T if for every execution of α on any input → x ∈XT in which at most one processor is faulty, the following two conditions hold: (1)

All the non-faulty processors eventually decide.

(2)

→). If no processor is faulty in the execution, then the output vector belongs to T(x

When such a protocol α exists we say that the task T is 1−solvable. The definition above does not require the processors to halt after reaching a decision. However, in the case of a single failure, it is not hard to see that a processor that learns that n −1 processors (including itself) have already decided may halt. Hence, in this case, reaching a decision by all non-faulty processors is sufficient to guarantee halting. For this reason, in this paper we shall restrict the discussion to protocols in which the processors are guaranteed to halt in every possible execution. (Note that in the case of t > 1 crash failures, there exist tasks which can be t-solved only by protocols that do not guarantee termination, e.g, the renaming tasks [ABDKPR]. For more on the termination requirement for multiple failures see [TKM]).

3. STANDARD PROTOCOLS AND ROUND COMPLEXITY In this paper we bound the number of communication rounds that are required by protocols that 1-solve a given task. This number attempts to capture the notion of time complexity for asynchronous fault tolerant protocols. We model an arbitrary t-resilient protocol that works in rounds of communications by the notion of standard protocol. The definitions and discussion below are restricted to the case t = 1. 3.1. Standard Protocols A protocol that 1-solves a task T is a standard protocol if it works in rounds of communications, as follows. In each round a processor broadcasts a message (which includes the round number), which is a function of its state, to all the processors (including itself), and waits until it receives n −1 messages of this round (including its own message which is received first; it may wait for less than n −1 messages if it heard of processors that had already halted). During this period of waiting, it might receive messages from different rounds. Those of higher rounds are saved until the processor itself reaches these rounds. Messages of previous rounds (there can be at most one such message from each previous round) are gathered with the n −1 messages of this round to form a set M. Then the processor computes its next state, which is a function of M and its previous state. The state of a processor includes its write-once register. Our notion of standard protocol is similar to the one used in [Fe]. Formally, the standard protocol for Pk is as follows: r←0 state ← INIT_k while state≠HALT do

5

r ← r +1 BROADCAST (r, MESSAGE_FUNCTION_k (state)) WAIT until you RECEIVE (n −1− [# of known halted processors]) messages of the form (r, *) M ← {m | a message (r′, m), r′≤r was received in the above WAIT, or a message (r, m) was received in a previous round} state ← STATE_FUNCTION_k (state, M) end

3.2. Round Complexity Definition: Let T be a task and α a standard protocol that 1-solves T. The round complexity of →), is the maximum round number, over all executions of α on input α on input → x, denoted rc α (x → x, that a non-faulty processor reaches. →). The round complexity of α, denoted rc α (T) is defined by: rc α (T) = sup rc α (x → x ∈X

T

The round complexity rc (T) of a task T is defined by: rc (T) = min {rc α (T) | α 1-solves T}. Note that rc (T) may be infinite; this is the case only when the input set XT is infinite, and for any protocol α that 1-solves T and for any constant C, there is an input → x such that → rc α (x ) > C. Definition: A 1-solvable task T is bounded if rc (T) is finite, and is unbounded otherwise. We will first present results for bounded tasks, and then extend them to results which are applicable for unbounded tasks as well.

4. COVERING FUNCTIONS AND RADII OF TASKS We first give some basic definitions from [BMZ] which are needed for this paper. 4.1 Adjacency Graphs, Partial Vectors, Covering Vectors and i-Anchors Definition: Let S ⊆ A n , for a given set A. Two vectors → s 1,→ s 2 ∈S are adjacent if they differ in exactly one entry. The adjacency graph of S, G (S) = (S, Es ), is an undirected graph, where → ,→ → → → → (s 1 s 2 )∈Es iff s 1 and s 2 are adjacent. For a task T and an input vector x for T, G (T (x )) is the decision graph of → x. Definition: A partial vector is a vector in which one of the entries is not specified; this entry is denoted by ’∗’. For a vector → s = (s 1 , . . . ,sn ), → s i denotes the partial vector obtained by assigning ∗ to the i-th entry of → s, i.e., → s i = (s 1 , . . . ,si −1 ,∗,si +1 , . . . ,sn ). → s is called an extension of

→ s i.



Definition: Let → x i be a partial input vector and d i a partial decision vector of a task T. We say →

that d i is a covering vector for → x i if for each extension of → x i to an input vector → x ∈XT , there is →



→). an extension of d i to a decision vector d ∈T (x

Note that in an execution on input → x in which the messages of Pi are delayed, the remain-

ing n −1 processors must eventually output a covering vector for → x i . If eventually Pi decides

6

too, then the resulting output vector is an i-anchor, which we define below. →





→) and d i is a covering vector Definition: A vector d is an i-anchor of an input vector → x if d ∈T (x

for → x i.

Example: Consider the OPR task (defined in Section 2.2) for n =3 processors and K =5. For the →

partial input vector → x 2 = (10,*, 30) there is a unique covering vector d 2 = (2,*, 4), and the → input vector → x = (10,20,30) has a unique 2-anchor d = (2,3,4). In the OPR task with n =3 and

K =6 there are three covering vectors for → x 2 : (2,*,4), (2,*,5), and (3,*,5). Thus, → x has four 2anchors: (2,3,4), (2,3,5), (2,4,5) and (3,4,5). 4.2 Covering Functions and Radii of Tasks

Definition: A covering function for a given task T is a function that maps each partial input vector to a corresponding covering vector for it. Definition: Let T be a task, CF a covering function for T, and → x ∈ XT an input vector. An → → anchors tree for x based on CF is a tree in G (T (x )) that, for each i (1≤i≤n), includes an i→ i ). anchor which is an extension of CF (x

We now reformulate Theorem 3 of [BMZ] to a form suitable to our discussion: Theorem [BMZ] : A task T is 1-solvable if and only if there exists a covering function CF for T, such that for each input vector → x ∈XT , there is an anchors tree for → x based on CF.  A covering function satisfying the condition of Theorem [BMZ] is termed a solving covering function for T. As we show in Section 6, such functions may be used to construct protocols that 1-solve T. Each solving covering function CF defines a radius function ρCF : XT → N, as follows.

→) is Definition: Let CF be a solving covering function for T, and → x an input vector in XT . ρCF (x the minimum possible radius of an anchors tree for → x based on CF. 2

The set of all radius functions for T is denoted by RT . That is, RT = {ρCF : CF is a solving covering function for T}. Definition: R (T), the radius of the task T, is given by: R (T) = min

ρCF ∈RT

→). sup ρCF (x

→ x ∈X

T

A covering function CF, and the corresponding radius function ρCF , are optimal for a task T if →) = R (T). R (T) is finite, and max ρCF (x → x ∈X

T

Note that R (T) may be infinite. This is the case only when the input set XT is infinite, and x such that for any radius function ρCF in RT and for any constant C, there is an input → → ρCF (x ) > C. As we shall show, R (T) is finite iff T is a bounded task. Example: Consider the following task T for n =3 processors, in which XT contains only 3 input  2

The radius of a tree T is the minimal integer r, such that for some vertex v in T, every vertex in T is at distance at most r from v.

7

vectors: → x 2 = (10,20,30) and → x 3 = (10,20,70). x 1 = (50,20,30), → → T (x 1 ) = { (5,2,3) }, → ) = { (1,2,3),(1,4,3),(5,4,3),(5,4,6),(7,4,6), (7,5,6),(7,5,8),(3,5,8),(3,2,8) } and T (x 2 → T (x ) = { (7,4,1),(3,2,1) } (see Figure 1) 3

Now, in choosing an optimal covering function for T, the only partial input vectors that should be considered are those which might be extended to more than one input vector (if → x i might be → →) is an i-anchor of → x, so the need to extended to a unique input vector → x, then any vector d in T (x select an i-anchor does not impose any constraint on the anchors tree). Thus we consider only (*,20,30) and (10,20,*), so the only anchors that constrain the anchors tree are the 1-anchor and the 3-anchor.

8

→ x

→ x

→ x

3

2

1

(*,20,30)

50,20,30

10,20,30

(10,20,*)

10,20,70

T T

CF 1 CF 2 1-anchor

5,2,3

.................

(*,2,3) .. .. .. .. .. .. .. .. .. .. .

T

1,2,3

CF 1

1,4,3 anchors tree based on CF 1 (radius 2)

CF 2 5,4,3 5,4,6 7,4,6

..................

(7,4,*) .. .. .. .. .. .. .. .. .. ..

7,4,1

3-anchor (by CF 1 ) 7,5,6 7,5,8 3,5,8 3-anchor (by CF 2 )

3,2,8

→ )) G (T (x 2

........ ....................

(3,2,*) .. .. .. .. ..

3,2,1

anchors tree based on CF 2 (radius 4)

→ )) Figure 1: A task T with R (T) = 2 (=ρCF 1 (x 2 → ), since any From the decision graphs in Figure 1, clearly R (T) is determined by T (x 2 anchors tree of the other two input vectors is composed of a single vertex. Based on the previous discussion, it suffices to consider only two covering functions, CF 1 and CF 2 , whose values on the two “key” partial vectors are as follows: CF 1 ( (*,20,30) ) = (*,2,3), CF 1 ( (10,20,*) ) = (7,4,*) and CF 2 ( (*,20,30) ) = (*,2,3), CF 2 ( (10,20,*) ) = (3,2,*). → )) ) the 1-anchor is (1,2,3), the In the minimum radius anchors tree based on CF 1 (in G (T (x 2

9

3-anchor is (7,4,6), and thus the radius is 2 (a line, with center (5,4,3) ). The anchors tree based on CF 2 has the same 1-anchor, its 3-anchor is (3,2,8), and its radius is 4. So CF 1 is the optimal covering function, and R (T) = 2. More examples appear in Section 8.

5. LOWER BOUND In this section we prove the following theorem. Theorem 1: Let T be a bounded task. Then its round complexity rc (T) satisfies rc (T) ≥ log(n −1) R (T). Proof: Let α be a standard protocol which 1-solves T, and rc α (T) = s. We will prove that α

→) ≤ (n −1)s for every input implies a solving covering function for T, CF α , such that ρCF α (x

vector → x, and thus R (T) ≤ (n −1)s . To simplify the presentation, we assume that in all executions of α no processor halts before round s (and hence that all processors halt in round s). Clearly, such an assumption does not affect the generality of the proof, since we can always modify α such that processors that halt in round r < s will continue to send "dummy" messages in later rounds. Note that this assumption enables us to assume that in each round, each processor waits for exactly n −1 messages (including its own message) of this round. For the proof we construct sequences of executions of α, which first require some definitions and discussion. Definition: e is an r-round execution of a standard protocol A if e is the first r rounds of an execution of A. e is an r-round i-sleeping execution if during e, no processor P j , j≠i, ever receives a message from Pi . Let e be an r-round execution of α, and let 1 ≤ l ≤ r. The l-senders of Pk in e is the set of processors from which Pk receives messages (l,*) in the l’th round of e. Note that the lsenders of Pk always contains Pk , and that its cardinality is n −1. Definition: An r-round execution e is an ordered execution if for each 1 ≤ k ≤n and for each 1 ≤ l ≤r, each processor Pk receives in round l exactly all the messages (t,*), t ≤ l, sent to it by its l-senders, and which it has not received yet. All the executions discussed in the rest of this section are ordered executions of the protocol α. Observe that an ordered r-round execution e is completely characterized by the inputs to the processors and by specifying the l-senders of each processor, for l = 1, . . . , r.

The history of a processor in an r-round execution e of α is defined by its input value, and the messages it receives in each round l from its l-senders, for l = 1, . . . , r. Proposition 1: Let f and f ′ be two r-round executions of α. Then Pk has the same history in f and f ′, if (and only if) in both executions it has the same r-senders, S, and each processor of S has the same history after the (r −1)-st round in f and f ′. (Note that Pk belongs to S.)  → i ) is the Next we define the solving covering function CF α . For a given → x and i, CF α (x →

partial vector d i output by the processors P−{Pi } in an s-round i-sleeping execution of α on input → x. (The validity of this definition follows from the fact that α 1-solves T in at most s

10

rounds, and thus by round s the processors P−{Pi } must decide on a covering vector). We now proceed to the main construction required for our proof, given in Lemma 1 below. This construction uses an idea of [Fe]. First we need the following definition and proposition: Definition: Two r-round executions are adjacent if there are at least n −1 processors, each of which has the same history in both executions. Proposition 2: Let f and f ′ be two r-round executions which are identical until round r −1, and assume there are two processors, each of which has the same r-senders in f and f ′. Then there is a sequence of n −1 r-round executions, CHAIN (f , f ′) = (f =f 1 , f 2 , . . . , fn −1 =f ′) such that fk and fk +1 are adjacent for k=1 .. n −2. Proof: For simplicity, assume that the two processors that have the same r-senders in f and f ′ are P 1 and Pn . Let the r-senders of the processors P 1 , . . . ,Pn in execution f be Q 1 ,Q 2 , . . . ,Qn −1 ,Qn (Qi is the r-senders of Pi ), and let the r-senders of the processors in execution f ′ be Q 1 ,Q′2 , . . . ,Q′n −1 ,Qn . Then CHAIN (f , f ′) = (f =f 1 , . . . , fn −1 =f ′), where for i = 2, . . . ,n −2, the first r −1 rounds of fi are identical to those of f and f ′, and the r senders of the processors P 1 , . . . ,Pn in fi are Q 1 ,Q′2 , . . . ,Q′i ,Qi +1 , . . . ,Qn .  Lemma 1: Let 1≤i 0, there exists a . . . ,eD of Dr = (n −1)r r-round executions of α, satisfying the following: sequence Sr = e 1 , r

(a)

(b)

x, and eDr is an r-round j-sleeping execue 1 is an r-round i-sleeping execution on input →

tion on input → x.

The executions ek and ek +1 are adjacent, for k=1, . . . , Dr −1.

Proof: The proof is by induction on r. (The base and the first step of the induction are depicted x in which the in Figure 2). For the base, r =1, e 1 is the 1-round i-sleeping execution on input → → 1-senders of Pi is P−{P j }, and en −1 is the 1-round j-sleeping execution on input x in which the 1-senders of P j is P−{Pi }. The sequence e 1 , . . . ,en −1 is CHAIN (e 1 ,en −1 ), which satisfies the conditions by Proposition 2 (the assumptions of Proposition 2 hold since Pi and P j have each the same 1-senders in e 1 and en −1 ). The induction step: Let Sr −1 = e 1 , . . . ,eD be a sequence satisfying the lemma for r −1 r −1

r −1

(Dr −1 = (n −1) ). Then for each k = 1, . . . ,Dr −1 −1 there is a set of n −1 processors, which we denote by Qk , such that each processor in Qk has the same history in ek and ek +1 . We construct the sequence Sr by replacing each (r −1)-round execution ek in Sr −1 by a sequence of n −1 r-round adjacent executions ek, 1 , ek, 2 , . . . ,ek,n −1 ; i.e., Sr = e 1,1 , . . . ,e 1,n −1 , . . . ,eD ,n −1 . It remains to define the executions ek, j and to prove that Sr indeed satisfies the r −1 lemma. First, to avoid special end-case treatments, we define Q 0 = P−{Pi } and QDr −1 = P−{P j }. Now, in ek, 1 the first r −1 rounds are identical to ek . In round r: The r-senders of each processor in Qk −1 is Qk −1 , and the r-senders of the remaining processor is Qk . In ek,n −1 the first r −1 rounds are also identical to ek . In round r: The r-senders of each processor in Qk is Qk , and the r-senders of the remaining processor is Qk −1 . Now by Proposition 2 we can define the

11

sequence ek, 1 , . . . ,ek,n −1 to be CHAIN (ek, 1 , ek,n −1 ). It remains to show that: (1) e 1,1 (i.e., the leftmost execution in Sr ) is an r-round i-sleeping execution and eDr −1 ,n −1 (i.e., the rightmost execution in Sr ) is an r-round j-sleeping execution. This follows immediately by the induction hypothesis and the construction. (2) Two successive executions in Sr are indeed adjacent. If the two executions are in the same CHAIN (that is, they are ek,i and ek,i +1 for some k and i) then this follows from Proposition 2. We now prove that this holds also in the case that these executions are from different CHAINs, i.e. they are of the form ek,n −1 and ek +1,1 for some k. By the construction, until round r −1 ek,n −1 is identical to ek and ek +1,1 is identical to ek +1 . By the induction hypothesis, each processor in Qk has the same history in ek and ek +1 (and thus has the same history after round r −1 in ek,n −1 and ek +1,1 ). By the construction, the r-senders of each processor in Qk , in both ek,n −1 , ek +1,1 is Qk , and thus, by Proposition 1, each of these n −1 processors has the same history in ek,n −1 and ek +1,1 .  We now use Lemma 1 to show that R(T) ≤ Ds = (n −1)s . For this, apply Lemma 1 for → →) (each processor decides in e r =s. Then each execution ek defines an output vector dk ∈T (x k since it performs round s in ek , and α guarantees that a processor that performs round s decides no later than round s; the decision value of each processor, and hence the complete output vector, are completely determined since ek is an ordered execution). Statement (a) of the lemma →



→ i ), and d is a j-anchor of → implies that d 1 is an i-anchor of → x which extends CF α (x x which Ds →



→ j ). Statement (b) of the lemma implies that for every k, d and d extends CF α (x k k +1 are either → ... → ,dDs ) is a path of length at most Ds −1 from an the same vector or are adjacent. Thus, (d 1 , → →)