TexPoint fonts used in EMF Read the TexPoint manual before you delete this box A A A A Companion slides for Distributed Computing Through Combinatorial Topology Maurice Herlihy ID: 760332
Download Presentation The PPT/PDF document "Solvability of Colorless Tasks in Differ..." is the property of its rightful owner. Permission is granted to download and print the materials on this web site for personal, non-commercial use only, and to display it on your personal computer provided you do not modify the materials and that you retain all copyright notices contained in the materials. By downloading content from our website, you accept the terms of this agreement.
Slide1
Solvability of Colorless Tasks in Different Models
TexPoint
fonts used in EMF.
Read the
TexPoint manual before you delete this box.: AAAA
Companion slides
forDistributed ComputingThrough Combinatorial TopologyMaurice Herlihy & Dmitry Kozlov & Sergio Rajsbaum
1
Slide2Road Map
Overview of Models
t-resilient layered snapshot models
Layered Snapshots with k-set agreement
Adversaries
Message-Passing Systems
Distributed Computing through Combinatorial Topology
Decidability
2
Slide3Road Map
Overview of Models
t-resilient layered snapshot models
Layered Snapshots with k-set agreement
Adversaries
Message-Passing Systems
Distributed Computing through Combinatorial Topology
Decidability
3
Slide4Skeleton
4
C
skel
1
C
skel
0
C
boo!
Slide5(I,O,¢) has a wait-free protocol iff
Parameter p
Distributed Computing through Combinatorial Topology
5
Model characterized by parameter p, 0 · p · n
there is a continuous map
f: |skelp I| |O|
carried
by
¢
.
Slide6Dimension of Skeleton map vsComputational Power
Distributed Computing through Combinatorial Topology
6
2-skeleton map
harder than
1-skeleton map
Slide7(I,O,¢) has a wait-free protocol …
Wait-Free Layered Immediate Snapshots
Distributed Computing through Combinatorial Topology
7
Up to n out of n+1 can crash
Just can’t wait (to be king)
if and only if …
there is a continuous map
f: |skeln I| |O|
carried by ¢.
Slide8(I,O,¢) has a wait-free protocol …
t-resilient Layered Immediate Snapshots
Distributed Computing through Combinatorial Topology
8
Up to t out of n+1 can crash
OK to wait for n-t+1
if and only if …
there is a continuous map
f: |skelt I| |O|
carried
by
¢
.
Slide9(I,O,¢) has a wait-free protocol …
Wait-Free Layered Immediate Snapshot with k-set Agreement
Distributed Computing through Combinatorial Topology
9
shared black boxes that solve k-set agreement
if and only if …
there is a continuous map
f: |skelk-1 I| |O|
carried
by
¢
.
Slide10Equivalent Models
Distributed Computing through Combinatorial Topology
10
t
-resilient model …
wait-free + t+1-set agreement …
have
identical
computational power!
Slide11Decidability
Distributed Computing through Combinatorial Topology
11
Is it decidable whether a task has a protocol ina model characterized by:
f: |skelp I| |O| ?
decidable if and only if
p
·
1
!
Slide12Road Map
Overview of Models
t-resilient layered snapshot models
Layered Snapshots with k-set agreement
Adversaries
Message-Passing Systems
Distributed Computing through Combinatorial Topology
Decidability
12
Slide13t-Resilient Layered Immediate Snapshot Protocol
Distributed Computing through Combinatorial Topology
13
shared
mem
array
0..N-1,0..n
of
Value
view := input
for
l
:= 0
to
N-1
do
do
immediate
mem
[
l
][
i
] := view;
snap := snapshot(
mem
[
l
][*])
until
|names(snap)| >= n+1-t
view := values(snap)
return
δ
(view)
Slide14t-Resilient Layered Immediate Snapshot Protocol
Distributed Computing through Combinatorial Topology
14
shared mem array 0..N-1,0..n of Valueview := inputfor l := 0 to N-1 do do immediate mem[l][i] := view; snap := snapshot(mem[l][*]) until |names(snap)| >= n+1-t view := values(snap)return δ(view)
2-dimensional memory array
row
is clean per-layer memory
column
is
per-process
word
Slide15t-Resilient Layered Immediate Snapshot Protocol
Distributed Computing through Combinatorial Topology
15
shared mem array 0..N-1,0..n of Valueview := inputfor l := 0 to N-1 do do immediate mem[l][i] := view; snap := snapshot(mem[l][*]) until |names(snap)| >= n+1-t view := values(snap)return δ(view)
initial view is input value
Slide16t-Resilient Layered Immediate Snapshot Protocol
Distributed Computing through Combinatorial Topology
16
shared mem array 0..N-1,0..n of Valueview := inputfor l := 0 to N-1 do do immediate mem[l][i] := view; snap := snapshot(mem[l][*]) until |names(snap)| >= n+1-t view := values(snap)return δ(view)
run for N layers
Slide17t-Resilient Layered Immediate Snapshot Protocol
Distributed Computing through Combinatorial Topology
17
shared mem array 0..N-1,0..n of Valueview := inputfor l := 0 to N-1 do do immediate mem[l][i] := view; snap := snapshot(mem[l][*]) until |names(snap)| >= n+1-t view := values(snap)return δ(view)
layer l : immediate write & snapshot of row l
Slide18t-Resilient Layered Immediate Snapshot Protocol
Distributed Computing through Combinatorial Topology
18
shared mem array 0..N-1,0..n of Valueview := inputfor l := 0 to N-1 do do immediate mem[l][i] := view; snap := snapshot(mem[l][*]) until |names(snap)| >= n+1-t view := values(snap)return δ(view)
wait to hear from n+1-t processes
why is this safe?
Slide19t-Resilient Layered Immediate Snapshot Protocol
Distributed Computing through Combinatorial Topology
19
shared mem array 0..N-1,0..n of Valueview := inputfor l := 0 to N-1 do do immediate mem[l][i] := view; snap := snapshot(mem[l][*]) until |names(snap)| >= n+1-t view := values(snap)return δ(view)
new view is set of values seen
Slide20t-Resilient Layered Immediate Snapshot Protocol
Distributed Computing through Combinatorial Topology
20
shared mem array 0..N-1,0..n of Valueview := inputfor l := 0 to N-1 do do immediate mem[l][i] := view; snap := snapshot(mem[l][*]) until |names(snap)| >= n+1-t view = values(snap)return δ(view)
finally apply decision map to final view
Slide2119
19
21
21
k
-set Agreement
k
= 2
Slide22(t+1)-Set Agreement
Distributed Computing through Combinatorial Topology
22
view := input
snap:
array
of
Value =
;
do
immediate
mem
[0][
i
] := view;
snap :=
snapshot(
mem
[0][*])
until
|names(snap)|
>= n+1-t
return
min
(values(view))
Slide23(t+1)-Set Agreement
Distributed Computing through Combinatorial Topology
23
view := inputsnap: array of Value = ;do immediate mem[0][i] := view; snap := snapshot(mem[0][*]) until |names(snap)| >= n+1-treturn min(values(view))
write input and take snapshot
Slide24(t+1)-Set Agreement
Distributed Computing through Combinatorial Topology
24
view := inputsnap: array of Value = ;do immediate mem[0][i] := view; snap := snapshot(mem[0][*]) until |names(snap)| >= n+1-treturn min(values(view))
wait to hear from n+1-t processes
Slide25(t+1)-Set Agreement
Distributed Computing through Combinatorial Topology
25
view := inputsnap: array of Value = ;do immediate mem[0][i] := view; snap := snapshot(mem[0][*]) until |names(snap)| >= n+1-treturn min(values(view))
return least value in view
can miss at most
t lesser values
most
t+
1
values returned
Slide26Informal Skeleton Lemma
Distributed Computing through Combinatorial Topology
26
If
And
We have a protocol for a task ...
Then
WLOG, we can “pre-process” with k-set agreement.
A protocol for
k
-set agreement …
Slide27Skeleton Lemma
Distributed Computing through Combinatorial Topology
27
If
And
protocol (I, P, ¥) solves task (I,O,¢)
Then
The composition of k-set agreement with (I,P,¥) also solves (I,O,¢).
There is a
k
-set agreement protocol for
I
Slide28Informal Protocol Complex Lemma
Distributed Computing through Combinatorial Topology
28
WLOG
We can assume that any protocol complex is a barycentric subdivision of the input complex.
Slide29Informal Protocol Complex Lemma
Distributed Computing through Combinatorial Topology
29
WLOG
We can assume that any protocol complex is a barycentric subdivision of the input complex.
Slide30Protocol Complex Lemma
Distributed Computing through Combinatorial Topology
30
If
There is a t-resilient layered protocol for (I,O,¢) ...
Then
Then there is a protocol (I,P,¥) such that …
P = BaryN(skelt I)
¥
(
¾
)
=
Bary
N
skel
t
(
¾
).
Slide31Theorem
Distributed Computing through Combinatorial Topology
31
The colorless task (I,O,¢) has a t-resilient layeredsnapshot protocol …
if and only if …
there is a continuous map
f: |skelt I| |O|
carried by ¢.
I
skel
1
(
I
)
Slide32Protocol Implies Map
Distributed Computing through Combinatorial Topology
32
May assume protocol complex is P = BaryN skelt I.
decision map
d: BaryN skelt I O
carried by ¢.
|d|: |BaryN skelt I| |O|
|d|: |skelt I| |O|
Slide33Simplicial Approximation Theorem
Given a continuous mapthere is an N such that f has a simplicial approximation
17-Feb-15
33
Slide34Map Implies Protocol
Distributed Computing through Combinatorial Topology
34
f: |skelt I| |O|
Á: BaryN skelt I O
Solve using …
barycentric agreement
t-set agreement
carried by ¢.
Slide35Road Map
Overview of Models
t-resilient layered snapshot models
Layered Snapshots with k-set agreement
Adversaries
Message-Passing Systems
Distributed Computing through Combinatorial Topology
Decidability
35
Slide36Motivation
Distributed Computing through Combinatorial Topology
36
Today …
Practically all modern multiprocessors provide synchronization more powerful than read-write …
Like …
test-and-set, compare-and-swap, ….
Here …
we
consider protocols constructed by
composing
layered
snapshot protocols with
k
-set
agreement protocols.
Slide37Wait-Free Layered Set Agreement Protocol
Distributed Computing through Combinatorial Topology
37
shared
mem
array
0..N-1,0..n
of
Value
shared
SA
array
0..N-1
of
SetAgree
view := input
for
l
:= 0
to
N-1
do
view: View := SA[
l
].decide(view)
immediate
mem
[
l
][
i
] := view;
snap := snapshot(
mem
[
l
][*])
view := values(snap)
return
δ
(view)
Slide38Wait-Free Layered Set Agreement Protocol
Distributed Computing through Combinatorial Topology
38
shared mem array 0..N-1,0..n of Valueshared SA array 0..N-1 of SetAgreeview := inputfor l := 0 to N-1 do view: View := SA[l].decide(view) immediate mem[l][i] := view; snap := snapshot(mem[l][*]) view := values(snap)return δ(view)
per-level shared memory
Slide39Wait-Free Layered Set Agreement Protocol
Distributed Computing through Combinatorial Topology
39
shared mem array 0..N-1,0..n of Valueshared SA array 0..N-1 of k-SetAgreeview := inputfor l := 0 to N-1 do view: View := SA[l].decide(view) immediate mem[l][i] := view; snap := snapshot(mem[l][*]) view := values(snap)return δ(view)
per-level k-set agreement object
Slide40Wait-Free Layered Set Agreement Protocol
Distributed Computing through Combinatorial Topology
40
shared mem array 0..N-1,0..n of Valueshared SA array 0..N-1 of k-SetAgreeview := inputfor l := 0 to N-1 do view: View := SA[l].decide(view) immediate mem[l][i] := view; snap := snapshot(mem[l][*]) view := values(snap)return δ(view)
initial view is input value
Slide41Wait-Free Layered Set Agreement Protocol
Distributed Computing through Combinatorial Topology
41
shared mem array 0..N-1,0..n of Valueshared SA array 0..N-1 of k-SetAgreeview := inputfor l := 0 to N-1 do view: View := SA[l].decide(view) immediate mem[l][i] := view; snap := snapshot(mem[l][*]) view := values(snap)return δ(view)
do k-set agreement with others at this level
Slide42Wait-Free Layered Set Agreement Protocol
Distributed Computing through Combinatorial Topology
42
shared mem array 0..N-1,0..n of Valueshared SA array 0..N-1 of k-SetAgreeview := inputfor l := 0 to N-1 do view: View := SA[l].decide(view) immediate mem[l][i] := view; snap := snapshot(mem[l][*]) view := values(snap)return δ(view)
then do immediate snapshot
Slide43Wait-Free Layered Set Agreement Protocol
Distributed Computing through Combinatorial Topology
43
shared mem array 0..N-1,0..n of Valueshared SA array 0..N-1 of k-SetAgreeview := inputfor l := 0 to N-1 do view: View := SA[l].decide(view) immediate mem[l][i] := view; snap := snapshot(mem[l][*]) view := values(snap)return δ(view)
new view is set of values seen
Slide44Protocol Complex Lemma
Distributed Computing through Combinatorial Topology
44
If (I,P,¥) is a k-set layered snapshot protocol …
then P is equal to BaryN skelk-1 I, …
for
some
N
¸
0
.
Slide45Theorem
Distributed Computing through Combinatorial Topology
45
The colorless task (I,O,¢) has a wait-free k-set layeredsnapshot protocol …
if and only if …
there is a continuous map
f: |skelk-1 I| |O|
carried
by
¢
.
Slide46Theorem
Distributed Computing through Combinatorial Topology
46
The colorless task (I,O,¢) has a wait-free k-set layeredsnapshot protocol …
if and only if …
there is a continuous map
f: |skelk-1 I| |O|
carried by ¢.
k
-1
skeleton, not
t
-skeleton!
Slide47Road Map
Overview of Models
t-resilient layered snapshot models
Layered Snapshots with k-set agreement
Adversaries
Message-Passing Systems
Distributed Computing through Combinatorial Topology
Decidability
47
Slide48Wait-Free
All but one can fail
Distributed Computing through Combinatorial Topology
Slide49t
-resilient
·
t
can fail
Distributed Computing through Combinatorial Topology
Slide50Irregular Failures
Same server
Different servers
Distributed Computing through Combinatorial Topology
Slide51http://pixabay.com/en/chess-figures-game-play-strategy-145184/
Adversaries
17-Feb-15
Distributed Computing through Combinatorial Topology
Walt Disney
Slide52Faulty Sets
These can fail
Or this …
Distributed Computing through Combinatorial Topology
Slide53Faulty Sets Closed under Containment
If both can fail …
So can only one
Never
require
failures
Distributed Computing through Combinatorial Topology
Slide54Failure Complex
17-Feb-15
54
Vertex per process
Distributed Computing through Combinatorial Topology
Slide55Failure Complex
17-Feb-15
55
Vertex per process
Simplex = faulty set
Distributed Computing through Combinatorial Topology
Slide56Irregular Failure Complex
17-Feb-15
56
Distributed Computing through Combinatorial Topology
Slide57Wait-Free Failure Complex
17-Feb-15
57
(
n
-1
)-skeleton
Distributed Computing through Combinatorial Topology
Slide58t-resilient Failure Complex
17-Feb-15
58
(
t-
1)
-skeleton
Distributed Computing through Combinatorial Topology
Slide59Cores
17-Feb-15
59
Minimal set of processes that cannot all fail
Safe to wait for at least one member of a particular core to show up
Distributed Computing through Combinatorial Topology
Slide60Cores & Failure Complex
17-Feb-15
60
Minimal simplex not in failure complex
Distributed Computing through Combinatorial Topology
Slide61Irregular Failure Complex
17-Feb-15
61
Distributed Computing through Combinatorial Topology
Slide62Wait-Free Failure Complex
17-Feb-15
62
All
n
+1
processes only core
Distributed Computing through Combinatorial Topology
Slide63t-resilient Failure Complex
17-Feb-15
63
Any
t
-simplex is a core
Any set of
t
+1
processes is a core
Distributed Computing through Combinatorial Topology
Slide64Cores
17-Feb-15
64
For many models,
Completely determines adversary’s power to solve any colorless task!
minimum core size…
So adversaries with same min core size solve the same colorless tasks
Distributed Computing through Combinatorial Topology
Slide65Survivor Sets
17-Feb-15
65
Minimal set of processes that might all survive
Safe to wait for all members of some survivor set to show up
Dual to cores: each one determines the other
Distributed Computing through Combinatorial Topology
Slide66Survivor Sets in Failure Complex
17-Feb-15
66
Complementary simplex in failure complex
Distributed Computing through Combinatorial Topology
Slide67Irregular Failure Complex
17-Feb-15
67
Survivor Sets
Distributed Computing through Combinatorial Topology
Slide68Wait-Free Failure Complex
17-Feb-15
68
Any vertex
Any individual process is a survivor set
Distributed Computing through Combinatorial Topology
Slide69t-resilient Failure Complex
17-Feb-15
69
Any (
n-t
)-simplex
Any set of
n-t+1
processes is a survivor set
Distributed Computing through Combinatorial Topology
Slide70A-Resilient Layered Immediate Snapshot Protocol
Distributed Computing through Combinatorial Topology
70
shared
mem
array
0..N-1,0..n
of
Value
view := input
for
l
:= 0
to
N-1
do
do
immediate
mem
[
l
][
i
] := view;
snap := snapshot(
mem
[
l
][*])
until
names(snap)
µ
survivor set
view := values(snap)
return
δ
(view)
Slide71A-Resilient Layered Immediate Snapshot Protocol
Distributed Computing through Combinatorial Topology
71
shared mem array 0..N-1,0..n of Valueview := inputfor l := 0 to N-1 do do immediate mem[l][i] := view; snap := snapshot(mem[l][*]) until names(snap) µ survivor set view := values(snap)return δ(view)
wait to hear from a survivor set
why is this safe?
Slide72Road Map
Overview of Models
t-resilient layered snapshot models
Layered Snapshots with k-set agreement
Adversaries
Message-Passing Systems
Distributed Computing through Combinatorial Topology
Decidability
72
Slide73Message Passing
Distributed Computing through Combinatorial Topology
73
that send and receive messages …
There are n+1 asynchronous processes …
via a fully-connected communication network.
Message
delivery is
reliable
and
FIFO
Slide74Message-Passing Protocols
Distributed Computing through Combinatorial Topology
74
decide after finite # steps
but protocol
forwards messages …
forever!
Slide75Communication Syntax
Distributed Computing through Combinatorial Topology
75
send(P, v0, …, vl) to Q
send(P, v0, …, vl) to all
upon
receive
(P,
v
0
, …,
v
l
)
do
...
//
handle message
Slide76Forwarding
Distributed Computing through Combinatorial Topology
76
background
// forward messages forever
upon
receive
(
P
j
,v
)
do
send
(
P
i
,v
)
to
all
Slide77Get Values from n+1-t Processes
Distributed Computing through Combinatorial Topology
77
getQuorum
():
Set of
Value
V:
Set of
Value :=
;
q:
int
:=
0
do
upon
receive(
Q,v
)
do
V
:= V
[
{v}
q := q + 1
until
q = n+1-t
return
V
Slide78Get Values from n+1-t Processes
Distributed Computing through Combinatorial Topology
78
getQuorum(): Set of Value V: Set of Value := ; q: int := 0 do upon receive(Q,v) do V := V [ {v} q := q + 1 until q = n+1-t return V
Initially, nothing.
Slide79Get Values from n+1-t Processes
Distributed Computing through Combinatorial Topology
79
getQuorum(): Set of Value V: Set of Value := ; q: int := 0 do upon receive(Q,v) do V := V [ {v} q := q + 1 until q = n+1-t return V
remember values and count
Slide80Get Values from n+1-t Processes
Distributed Computing through Combinatorial Topology
80
getQuorum(): Set of Value V: Set of Value := ; q: int := 0 do upon receive(Q,v) do V := V [ {v} q := q + 1 until q = n+1-t return V
safe to wait for n+1-t values
Slide81Get Values from n+1-t Processes
Distributed Computing through Combinatorial Topology
81
getQuorum(): Set of Value V: Set of Value := ; q: int := 0 do upon receive(Q,v) do V := V [ {v} q := q + 1 until q = n+1-t return V
return values when enough received
Slide82Protocol for (t+1)-Set Agreement
Distributed Computing through Combinatorial Topology
82
SetAgree
(v
i
):
value
send(P, v
i
)
to
all
V:
Set of
Value :=
getQuorum
()
return
min(V)
Slide83Protocol for (t+1)-Set Agreement
Distributed Computing through Combinatorial Topology
83
SetAgree(v): value send(P, v) to all V: Set of Value := getQuorum() return min(V)
broadcast my value
Slide84Protocol for (t+1)-Set Agreement
Distributed Computing through Combinatorial Topology
84
SetAgree(v): value send(P, v) to all V: Set of Value := getQuorum() return min(V)
get values from all but t
Slide85Protocol for (t+1)-Set Agreement
Distributed Computing through Combinatorial Topology
85
SetAgree(v): value send(P, v) to all V: Set of Value := getQuorum() return min(V)
return min value received
possible to “miss” only
t
lesser values
Slide8686
Barycentric Agreement
Distributed Computing through Combinatorial Topology
I
Bary
I
Slide87Barycentric Agreement Protocol
Distributed Computing through Combinatorial Topology
87
BaryAgree
(v
i
:
Vertex):
set of
Vertex
V
i
:
set of
Vertex := {
v
i
}
count:
int
:= 0
while
count < n+1-t do
send(P
i
, V
i
)
to all
on
receive(
P
j
,
V
j
)
do
if
V
i
=
V
j
then
count
:= count + 1
else
if
V
j
n
V
i
;
then
V
i
:=
V
i
[
V
j
count := 0
return
V
i
Slide88Barycentric Agreement Protocol
Distributed Computing through Combinatorial Topology
88
BaryAgree(vi: Vertex): set of Vertex Vi: set of Vertex := {vi} count: int := 0 while count < n+1-t do send(Pi, Vi) to all on receive(Pj, Vj) do if Vi = Vj then count := count + 1 else if Vj n Vi ; then Vi := Vi [ Vj count := 0 return Vi
Set of messages Pi has received
Barycentric Agreement Protocol
Distributed Computing through Combinatorial Topology
89
BaryAgree(vi: Vertex): set of Vertex Vi: set of Vertex := {vi} count: int := 0 while count < n+1-t do send(Pi, Vi) to all on receive(Pj, Vj) do if Vi = Vj then count := count + 1 else if Vj n Vi ; then Vi := Vi [ Vj count := 0 return Vi
keep track of confirmations received so far
Barycentric Agreement Protocol
Distributed Computing through Combinatorial Topology
90
BaryAgree(vi: Vertex): set of Vertex Vi: set of Vertex := {vi} count: int := 0 while count < n+1-t do send(Pi, Vi) to all on receive(Pj, Vj) do if Vi = Vj then count := count + 1 else if Vj n Vi ; then Vi := Vi [ Vj count := 0 return Vi
get confirmation from each non-faulty process
Barycentric Agreement Protocol
Distributed Computing through Combinatorial Topology
91
BaryAgree(vi: Vertex): set of Vertex Vi: set of Vertex := {vi} count: int := 0 while count < n+1-t do send(Pi, Vi) to all on receive(Pj, Vj) do if Vi = Vj then count := count + 1 else if Vj n Vi ; then Vi := Vi [ Vj count := 0 return Vi
broadcast message set received
Barycentric Agreement Protocol
Distributed Computing through Combinatorial Topology
92
BaryAgree(vi: Vertex): set of Vertex Vi: set of Vertex := {vi} count: int := 0 while count < n+1-t do send(Pi, Vi) to all on receive(Pj, Vj) do if Vi = Vj then count := count + 1 else if Vj n Vi ; then Vi := Vi [ Vj count := 0 return Vi
collect responses
Barycentric Agreement Protocol
Distributed Computing through Combinatorial Topology
93
BaryAgree(vi: Vertex): set of Vertex Vi: set of Vertex := {vi} count: int := 0 while count < n+1-t do send(Pi, Vi) to all on receive(Pj, Vj) do if Vi = Vj then count := count + 1 else if Vj n Vi ; then Vi := Vi [ Vj count := 0 return Vi
remember if message confirms my view
Barycentric Agreement Protocol
Distributed Computing through Combinatorial Topology
94
BaryAgree(vi: Vertex): set of Vertex Vi: set of Vertex := {vi} count: int := 0 while count < n+1-t do send(Pi, Vi) to all on receive(Pj, Vj) do if Vi = Vj then count := count + 1 else if Vj n Vi ; then Vi := Vi [ Vj count := 0 return Vi
otherwise learned something new, start over
Barycentric Agreement Protocol
Distributed Computing through Combinatorial Topology
95
BaryAgree(vi: Vertex): set of Vertex Vi: set of Vertex := {vi} count: int := 0 while count < n+1-t do send(Pi, Vi) to all on receive(Pj, Vj) do if Vi = Vj then count := count + 1 else if Vj n Vi ; then Vi := Vi [ Vj count := 0 return Vi
return when enough agree
Wait, There’s More!
Distributed Computing through Combinatorial Topology
96
background upon receive(Pj, Vj) do Vi := Vi [ Vj send(Pi, Vi) to all
the operating system runs forever …
Wait, There’s More!
Distributed Computing through Combinatorial Topology
97
background upon receive(Pj, Vj) do Vi := Vi [ Vj send(Pi, Vi) to all
keep forwarding new values
Lemma: Protocol Terminates
Distributed Computing through Combinatorial Topology
98
BaryAgree(vi: Vertex): set of Vertex Vi: set of Vertex := {vi} count: int := 0 while count < n+1-t do send(Pi, Vi) to all on receive(Pj, Vj) do if Vi = Vj then count := count + 1 else if Vj n Vi ; then Vi := Vi [ Vj count := 0 return Vi
Suppose BWOC Pi runs forever …
Eventually Vi assumes final value V …
Non-faulty Pj, where Vj = V’, receives V
Pj must have sent Vj to Pi
Vj ½ V
Vj = V
OR
Pj will sent V to Pi
P
j
has sent
V
to
P
i
Slide99All Vi, Vj Totally Ordered
Distributed Computing through Combinatorial Topology
99
BaryAgree(vi: Vertex): set of Vertex Vi: set of Vertex := {vi} count: int := 0 while count < n+1-t do send(Pi, Vi) to all on receive(Pj, Vj) do if Vi = Vj then count := count + 1 else if Vj n Vi ; then Vi := Vi [ Vj count := 0 return Vi
If Pi broadcasts V(0), …, V(k), then V(i) ½ V(i+1)
To decide …
P
i received Vi from X, |X| ¸ n+1-t
Pj received Vj from Y, |Y| ¸ n+1-t
some Pk 2 X Å Y sent both Vi, Vj
so
V
i
,
V
j
are ordered.
Slide100Theorem
Distributed Computing through Combinatorial Topology
100
For 2t < n+1, colorless task (I,O,¢) has a t-resilient message-passing protocol …
if and only if …
there is a continuous map
f: |skelt I| |O|
carried
by
¢
.
Slide101Theorem
Distributed Computing through Combinatorial Topology
101
For 2t < n+1, colorless task (I,O,¢) has a t-resilient message-passing protocol …
if and only if …
there is a continuous map
f: |skelt I| |O|
carried by ¢.
same as snapshot when
2t < n+1
!
Slide102Road Map
Overview of Models
t-resilient layered snapshot models
Layered Snapshots with k-set agreement
Adversaries
Message-Passing Systems
Distributed Computing through Combinatorial Topology
Decidability
102
Slide103Automatic Proofs?
17-Feb-15
103
What if we could program a Turing machineto tell whether a task has a protocol?
In wait-free read-write memory?
Or other models?
We could …
automatically generate conference papers
No need for grad students
Slide104Alas no
17-Feb-15
104
Whether a protocol exists for a task in …
Read-write memory for 3+ processes …
Read-write memory & k-set agreement …
Is undecidable.
for
k
> 2
Slide105Loop Agreement
17-Feb-15
105
Complex
Loop
Three
rendez-vous
points
Slide10617-Feb-15
106
One Rendez-Vous Point
Input
Output
Slide10717-Feb-15
107
Two
Rendez-Vous
Points
Input
Output
Any simplex on path between
Slide10817-Feb-15
108
Three
Rendez-Vous
Points
Input
Output
Any simplex
Slide109Contractibility
17-Feb-15
109
not contractible
contractible
Slide110Solvable Iff Loop Contractible
17-Feb-15
110
InputComplex
Output Complex
Slide111Undecidability
17-Feb-15
111
But Contractiblity is undecidable …
even for finite complexes!
(reduces to the word problem for finitely-presented groups)
Undecidable
whether a task has a protocol in wait-free read-write memory
Slide112Other Models
17-Feb-15
112
Wait-free read-write memory plus k-set agreement , for k > 2
Implies contractible, for k > 2
Undecidable whether a task has a protocol in wait-free read-write memory plus k-set agreement , for k > 2
Solvable iff
f
:
skel
k-1
I
*
O
*
exists …
Slide113113
This work is licensed under a Creative Commons Attribution-ShareAlike 2.5 License.
You are free:
to Share — to copy, distribute and transmit the work to Remix — to adapt the work Under the following conditions:Attribution. You must attribute the work to “Distributed Computing through Combinatorial Topology” (but not in any way that suggests that the authors endorse you or your use of the work). Share Alike. If you alter, transform, or build upon this work, you may distribute the resulting work only under the same, similar or a compatible license. For any reuse or distribution, you must make clear to others the license terms of this work. The best way to do this is with a link tohttp://creativecommons.org/licenses/by-sa/3.0/. Any of the above conditions can be waived if you get permission from the copyright holder. Nothing in this license impairs or restricts the author's moral rights.
Distributed Computing through Combinatorial Topology