Upper Bound on the Complexity of Solving Renaming Ami Paz, Technion Joint work with: Hagit Attiya, Technion Armando Castañeda, Technion Maurice Herlihy, Brown PODC 2013 Best Student Paper Award
Introduction 2
The Model ... p 1 p 2 p 3 p n Atomic Read/Write n asynchronous processes. At most n – 1 processes can crash. Wait-free algorithms: each nonfaulty process produces an output. Full information. 3
Iterated Atomic Snapshot Execution induced by a sequence of blocks: Write together; Read together. Fresh copy of the memory every time. Implemented in 𝑃 𝑜 2 overhead [Borowsky and Gafni 97] . 4
Comparison Based Algorithms Processes only compare their identifiers. Execution by P 1 , P 2 , P 3 looks like execution by P 1 , P 2 , P 4 . p 1 p 3 p 1 p 2 p 3 p 1 p 4 p 1 p 2 p 4 5
M -Renaming [Attiya et al. 90] 5 8 2 n processes Outputs: 1 ,…, M Unique values With identifiers Processes are only allowed to compare their identifiers 6
Weak Symmetry Breaking (WSB) [Gafni et al. 06] 1 1 0 n processes Outputs: 0/1 If all output: not all the same With identifiers Processes are only allowed to compare their identifiers 7
M -Renaming Bounds n +1,...,2 n -2 n +1,...,2 n -2 2 n -1,... 2 n -1,... M : 1 ,...,n 1 ,...,n WSB WSB Several Papers [Attiya et al. 90] [Attiya et al. 90] 8
M -Renaming Bounds [Castañeda and Rajsbaum 10]: Lower bounds are wrong. n +1,... n +1,... 2 n -1,... 2 n -1,... M : 1 ,...,n 1 ,...,n 2 n -2 2 n -2 n WSB WSB Prime Power Non ? Prime Power 9
Renaming Bounds [Castañeda and Rajsbaum 10]: Lower bounds are wrong. Existential proof. No bounds on steps complexity. 10
Our Results n -process algorithm for WSB and (2𝑜 − 2) -renaming, when n is not a prime power. Bounded step complexity: 𝑃(𝑜 𝑟+5 ) , where q is the largest prime power dividing n. 11
Topology & Distributed Computing 12
Simplexes Sets of objects. Represented as convex hulls of points. 𝑦 𝑦, 𝑧 𝑦, 𝑧, 𝑨 𝑦, 𝑧, 𝑨, 𝑥 13
Simplicial Complexes “ Gluings ” of simplexes. Some complexes are called subdivisions of others. 14
Topology & Distributed Computing [Borowsky and Gafni 93]; [Herlihy and Shavit 93,99]; [Saks and Zaharoglou 93,00]; [Herlihy and Rajsbaum 94,00]. Simplicial complexes represent states of the system. y a x x z z 15
Topology & Distributed Computing [Borowsky and Gafni 93]; [Herlihy and Shavit 93,99]; [Saks and Zaharoglou 93,00]; [Herlihy and Rajsbaum 94,00]. Simplicial complexes represent states of the system. (x, y, z) (x, a, z) Colored. 16
Topology & Distributed Computing An execution. x x,y x,y x,y 17
Topology & Distributed Computing An execution. x x,y x,y x,y x,y y All 1-step interleaving. x x,y x,y y 18
Subdivision Implies Algorithm Simplicial approximation: processes converge on a simplex. 19
Subdivision Implies Algorithm Execution: 20
Subdivision Implies Algorithm Execution: 21
Subdivision Implies Algorithm Execution: 22
Subdivision Implies Algorithm Execution: 23
Subdivision Implies Algorithm Execution: 24
Subdivision Implies Algorithm Execution: 25
Outputs Each vertex has double coloring: Process id Output value 26
Subdivision Implies Algorithm Simplicial approximation 0 0 1 0 1 0 0 1 1 1 0 0 27
Chromatic Subdivisions Chromatic subdivision: can assign a process to each vertex. An algorithm is induced by a specific subdivision: Standard chromatic subdivision. Simplex Standard Subdivision Second subdivision: S ... Std K ( S ) Std( S ) Std 2 ( S ) 28
Topological Notions Simplicial complex Subdivision Chromatic Subdivision Standard chromatic Subdivision 29
Topology & Distributed Computing Chromatic Distributed Subdivision Algorithm 30
From Subdivision to Algorithm Standard Chromatic Distributed Chromatic Subdivision Algorithm Subdivision simulated ← 0 Write(initialState i ) to R i while true do r ← Scan (R 0 ,...,R n − 1 ) if r contains all then return simulated simulated ← 1 Execute Local A (r) if A returns v then return the same value v Write ( r) to R 31 …
Colored Simplicial Approximation [Herlihy and Shavit 99] Standard Chromatic Chromatic Subdivision Subdivision Colored simplicial approximation theorem: any chromatic subdivided simplex can be “approximated” by a standard chromatic subdivision std K ( S ) … …for large enough K. Yields no bound on K . 32
Subdivision Implies Algorithm Standard Distributed Chromatic Algorithm Subdivision We count subdivisions, to get the step complexity. 33
Solving WSB Properties of the desired solution 34
Recall: WSB [Gafni et al. 06] 1 1 0 n Processes Outputs: 0/1 If all output: not all the same With identifiers Processes are only allowed to compare their identifiers 35
Binary Outputs All output values are binary. 1 0 0 0 0 1 0 1 1 1 1 0 36
Monochromatic Simplexes Represent executions with a single output. Forbidden! 37
Comparison Based Algorithms Processes only compare their values. Execution by P 1 , P 2 , P 3 looks like execution by P 1 , P 2 , P 4 . p 1 p 3 p 1 p 2 p 3 p 1 p 4 p 1 p 2 p 4 Topology: implies symmetry on the boundary. 38
Who is Bigger? 39
Symmetric Output Coloring 40
Three Steps to Solution 41
Our Goal Construct a subdivided simplex & coloring, s.t.: Symmetric coloring on the boundry. Without monochromatic simplexes. Standerd chromatic subdivision. 42
Three Step Plan Step 1: find a symmetric subdivision with only good monochromatic simplexes. Step 2: eliminate mono. simplexes, while preserving symmetry. Step 3: get a mapping from standard subdivision, yielding a WSB coloring and algorithm. 43
Step One: Symmetric Boundary 44
1. Create Boundary Start by creating a symmetric boundary. Each i -face is subdivided and colored: Create 𝑙 𝑗 0-mono. simplexes, for some integer 𝑙 𝑗 . Number of i -faces = 𝑜 𝑗 . 45
1. Fill in the Interior Add internal 0-mono. simplex. More 0-mono. simplexes are created. Total number of mono.: 𝑜−1 1 + 𝑜 𝑙 𝑗 𝑗 𝑗=1 46
1. Counting Mono. Simplexes Each 𝑙 𝑗 has a sign. We want: 𝑜−1 1 + 𝑜 𝑙 𝑗 = 0 𝑗 𝑗=1 47
1. Creating the Boundary We want: 1 + 𝑜 𝑗 𝑙 𝑗 = 0 . Subdivide boundaries simultaneously. 𝑃(1) subdivisions. 48
Step Two: Eliminating Mono. Simplexes 49
Eliminating Monochromatic Simplexes Use subdivisions to eliminate monochromatic simplexes. While preserving symmetry on the boundary. Adjacent case. 50
Eliminating Monochromatic Simplexes Use subdivisions to eliminate monochromatic simplexes. Non Adjacent case. 51
Eliminating Monochromatic Simplexes We can use subdivisions to eliminate monochromatic simplexes. Similar constructions for longer paths. 𝑃(ℓ) subdivisions for ℓ -length path. 52
Odd Paths Eliminate odd length paths? Impossible! We can eliminate only simplexes of even distance. 53
Signs Give each maximal simplex a sign. Can eliminate only opposite signs. Count monochromatic simplexes by their sign. This is an invariant. 54
2. Create Path Choose mono. simplexes of opposite signs. Find a connecting path. 55
2. Eliminate Choose mono. simplexes of opposite signs. Find a connecting path Eliminate. 56
2. Longer Paths Path between simplexes of opposite signs. The longer the path, more subdivisions are needed. 57
2. Longer Paths Path between simplexes of opposite signs. The longer the path, more subdivisions are needed. Solution: Break into short paths. Many n -length paths, subdivided simultaneously in 𝑃 𝑜 . 58
2. Eliminate Paths Match all simplexes in pairs. Eliminate pairs. Cannot be done simultaneously. 59
2. Number of paths Number of paths: Half the number of mono. simplexes: 𝑜−1 1 1 + 𝑜 ∈ 𝑃 𝑜 𝑟+2 𝑙 𝑗 2 𝑗 𝑗=1 q is the largest prime power dividing n . 60
2. Number of Subdivisions The “expensive” part: A simplex shared by many paths is subdivided many times. 𝑃 𝑜 𝑟+3 subdivisions. 61
Step Three: The Output Map 62
Cone Subdivision Simplex S Cone subdivision Second cone subdivision L -cone ... 63 subdivision
Cone Subdivision Simplex S Cone subdivision Second cone subdivision ... L -cone 64 subdivision
Constructing Subdivisions 1. Pick simplexes and an integer L . 2. L -cone (in parallel) these simplexes. 3. Extend to all simplexes. 65
Recommend
More recommend