Presentation is loading. Please wait.

Presentation is loading. Please wait.

048866: Packet Switch Architectures Dr. Isaac Keslassy Electrical Engineering, Technion MSM.

Similar presentations


Presentation on theme: "048866: Packet Switch Architectures Dr. Isaac Keslassy Electrical Engineering, Technion MSM."— Presentation transcript:

1 048866: Packet Switch Architectures Dr. Isaac Keslassy Electrical Engineering, Technion isaac@ee.technion.ac.il http://comnet.technion.ac.il/~isaac/ MSM (Maximum Size Matching) and MWM (Maximum Weight Matching)

2 Spring 2006048866 – Packet Switch Architectures2 Achieving 100% throughput 1. Switch model 2. Uniform traffic  Technique: Uniform schedule (easy) 3. Non-uniform traffic, but known traffic matrix  Technique: Non-uniform schedule (Birkhoff-von Neumann) 4. Unknown traffic matrix  Technique: Lyapunov functions (MWM) 5. Faster scheduling algorithms  Technique: Speedup (maximal matchings)  Technique: Memory and randomization (Tassiulas)  Technique: Twist architecture (buffered crossbar) 6. Accelerate scheduling algorithm  Technique: Pipelining  Technique: Envelopes  Technique: Slicing 7. No scheduling algorithm  Technique: Load-balanced router

3 Spring 2006048866 – Packet Switch Architectures3 Unknown Traffic Matrix  We want to maximize throughput  Traffic matrix unknown  cannot use BvN  Idea: maximize instantaneous throughput  In other words: transfer as many packets as possible at each time-slot  Maximum Size Matching (MSM) algorithm

4 Spring 2006048866 – Packet Switch Architectures4 Maximum Size Matching (MSM)  MSM maximizes instantaneous throughput  MSM algorithm: among all maximum size matches, pick a random one Q 11 (n)>0 Q N1 (n)>0 Request Graph Bipartite Match Maximum Size Match

5 Spring 2006048866 – Packet Switch Architectures5 Question  Is the intuition right?  Answer: No, there is a counter-example for which, in a given VOQ (i,j), ij <  ij

6 Spring 2006048866 – Packet Switch Architectures6 Counter-example Three possible matches, S(n): Consider the following non-uniform traffic pattern, with Bernoulli IID arrivals:

7 Spring 2006048866 – Packet Switch Architectures7 Simulation of simple 3x3 example

8 Spring 2006048866 – Packet Switch Architectures8 Idea: Use Lyapunov

9 Spring 2006048866 – Packet Switch Architectures9 Some definitions

10 Spring 2006048866 – Packet Switch Architectures10 Some definitions

11 Spring 2006048866 – Packet Switch Architectures11 Problem

12 Spring 2006048866 – Packet Switch Architectures12 Maximum Weight Matching (MWM) A 1 (n) N N Q NN (n) A 1N (n) A 11 (n) Q 11 (n) 11 A N (n) A NN (n) A N1 (n) D 1 (n) D N (n) Q 11 (n) Q N1 (n) “Request” Graph Bipartite Match S*(n) Maximum Weight Match “LQF” MWM Algorithm

13 Spring 2006048866 – Packet Switch Architectures13 Outline of Proof Note: proof based on paper by McKeown et al.

14 Spring 2006048866 – Packet Switch Architectures14 Proof  Let’s prove:  First, we’ll work with the approximate Lyapunov function  We’ll assume that there exists some  such that:  For all i,  j ij ≤ 1-   For all j,  i ij ≤ 1-   In other words, · (1-  ) m with m doubly stochastic

15 Spring 2006048866 – Packet Switch Architectures15 Proof

16 Spring 2006048866 – Packet Switch Architectures16 Proof

17 Spring 2006048866 – Packet Switch Architectures17 Proof  We worked with the approximate Lyapunov function  Now, let’s work with the real Lyapunov function, and show that

18 Spring 2006048866 – Packet Switch Architectures18 End of Proof

19 Spring 2006048866 – Packet Switch Architectures19 Review of Proof

20 Spring 2006048866 – Packet Switch Architectures20 Review of Proof

21 Spring 2006048866 – Packet Switch Architectures21 LQF (Longest Queue First)  LQF is the name given to the maximum weight matching, where weight w ij (n) = L ij (n).  But the name is so bad that people keep the name “MWM”!  LQF doesn’t necessarily serve the longest queue.  LQF can leave a short queue unserved indefinitely.  However, MWM-LQF is very important theoretically: most (if not all) scheduling algorithms that provide 100% throughput for unknown traffic matrices are variants of MWM!

22 Spring 2006048866 – Packet Switch Architectures22 LQF (Longest Queue First)  Question: what if or  What if weight w ij (n) = W ij (n) (waiting time)?  Preference is given to cells that have waited a long- time.  Is it stable?  We call the algorithm OCF (Oldest Cell First).  Remember that it doesn’t guarantee to serve the oldest cell!

23 Spring 2006048866 – Packet Switch Architectures23 OCF (Oldest Cell First) C ij (n) C ij (n+l) nn+l C ij (n) C ij (n+l) W ij (n)  ij (n)

24 Spring 2006048866 – Packet Switch Architectures24 Rough outline of proof Expectation given W(n) Note: full proof in paper by McKeown et al.

25 Spring 2006048866 – Packet Switch Architectures25 Implementing MSM  How can we find maximum size matches?  We do so by recasting the problem as a network flow problem

26 Spring 2006048866 – Packet Switch Architectures26 Network Flows Source s Sink t ac bd 10 1 1 1 Let G = [V,E] be a directed graph with capacity cap(v,w) on edge [v,w]. A flow is an (integer) function, f, that is chosen for each edge so that We wish to maximize the flow allocation.

27 Spring 2006048866 – Packet Switch Architectures27 A maximum network flow example By inspection Source s Sink t ac bd 10 1 1 1 Step 1: Source s Sink t ac bd 10, 10 10 10, 10 1 1 1 10 10, 10 Flow is of size 10

28 Spring 2006048866 – Packet Switch Architectures28 A maximum network flow example Source s Sink t ac bd 10, 10 10, 1 10, 10 1 1 1, 1 10, 1 10, 10 Step 2: Flow is of size 10+1 = 11 Source s Sink t ac bd 10, 10 10, 2 10, 9 1,1 10, 2 10, 10 Maximum flow: Flow is of size 10+2 = 12 Not obvious

29 Spring 2006048866 – Packet Switch Architectures29 Ford-Fulkerson Method of Augmenting Paths 1. Set f(v,w) = -f(w,v) on all edges. 2. Define a Residual Graph, R, in which res(v,w) = cap(v,w) – f(v,w) 3. Find paths from s to t for which there is positive residue. 4. Increase the flow along the paths to augment them by the minimum residue along the path. 5. Keep augmenting paths until there are no more to augment.

30 Spring 2006048866 – Packet Switch Architectures30 Example of Residual Graph st ac bd 10, 10 10 10, 10 1 1 1 10 10, 10 Flow is of size 10 t ac bd 10 1 1 1 s res(v,w) = cap(v,w) – f(v,w) Residual Graph, R Augmenting path

31 Spring 2006048866 – Packet Switch Architectures31 Example of Residual Graph st ac bd 10, 10 10, 1 10, 10 1 1 1, 1 10, 1 10, 10 Step 2: Flow is of size 10+1 = 11 st ac bd 10 1 1 1 1 1 Residual Graph 9 9

32 Spring 2006048866 – Packet Switch Architectures32 Complexity of network flow problems  In general, it is possible to find a solution by considering at most |V|.|E| paths, by picking shortest augmenting path first.  There are many variations, such as picking most augmenting path first.

33 Spring 2006048866 – Packet Switch Architectures33 Finding a maximum size match  How do we find the maximum size match? A B C D E F 1 2 3 4 5 6

34 Spring 2006048866 – Packet Switch Architectures34 Network flows and bipartite matching Finding a maximum size bipartite matching is equivalent to solving a network flow problem with capacities and flows of size 1. A1 Source s Sink t B C D E F 2 3 4 5 6

35 Spring 2006048866 – Packet Switch Architectures35 Example: Maximum Size Matching Ford-Fulkerson method A1 s t B C D E F 2 3 4 5 6 Residual Graph for first three paths:

36 Spring 2006048866 – Packet Switch Architectures36 Example: Maximum Size Matching Ford-Fulkerson method A1 s t B C D E F 2 3 4 5 6 Residual Graph for next two paths:

37 Spring 2006048866 – Packet Switch Architectures37 Example: Maximum Size Matching Ford-Fulkerson method A1 s t B C D E F 2 3 4 5 6 Residual Graph for augmenting path:

38 Spring 2006048866 – Packet Switch Architectures38 Example: Maximum Size Matching Ford-Fulkerson method A1 s t B C D E F 2 3 4 5 6 Residual Graph for last augmenting path: Note that the path augments the match: no input and output is removed from the match during the augmenting step.

39 Spring 2006048866 – Packet Switch Architectures39 Example: Maximum Size Matching Ford-Fulkerson method A1 s t B C D E F 2 3 4 5 6 Maximum flow graph:

40 Spring 2006048866 – Packet Switch Architectures40 Example: Maximum Size Matching Ford-Fulkerson method A1 B C D E F 2 3 4 5 6 Maximum Size Matching:

41 Spring 2006048866 – Packet Switch Architectures41 LPF (Largest Port First) Note: full proof in paper by Mekkitikul and McKeown

42 Spring 2006048866 – Packet Switch Architectures42 LPF


Download ppt "048866: Packet Switch Architectures Dr. Isaac Keslassy Electrical Engineering, Technion MSM."

Similar presentations


Ads by Google