1 / 47

Efficient Multidimensional Packet Classification with Fast Updates

Efficient Multidimensional Packet Classification with Fast Updates. Author: Yeim-Kuan Chang Publisher: IEEE TRANSACTIONS ON COMPUTERS, VOL. 58, NO. 4, APRIL 2009 Presenter: Chen-Yu Chang Date: 2009/3/17. Outline. One-Dimensional Packet Classification

marcie
Download Presentation

Efficient Multidimensional Packet Classification with Fast Updates

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Efficient Multidimensional Packet Classification with Fast Updates Author: Yeim-Kuan Chang Publisher: IEEE TRANSACTIONS ON COMPUTERS, VOL. 58, NO. 4, APRIL 2009 Presenter: Chen-Yu Chang Date: 2009/3/17

  2. Outline • One-Dimensional Packet Classification • Multidimensional Packet Classification • Performance Evaluation

  3. One-Dimensional Packet Classification • 1. Proposed Binary Search for Prefixes • Simple k-Bit Segmentation Table • k-Bit Segmentation Table and k_Set • Simple k_Set • 2. Proposed Binary Search for Ranges • Simple k-Bit Segmentation Table • k-Bit Segmentation Table and k_Set • Simple k_Set

  4. Proposed Binary Search for Prefixes(1/6) • Definition 1: The inequality 0 < * < 1 is used to compare two prefixes in ternary format. • Definition 2: For a prefix of length i, bW-1, … , bW-i , where bj = 0 or 1 for W-1 > j > W-i, its binary representation is bW-1, … , bW-i10, … ,0 with W-i trailing zeros. Ex: 0000-0*** can be represented as 0000-0100-0.

  5. Proposed Binary Search for Prefixes(2/6) • Ex: Dst = 00010 C → D → no prefix match • we generate some auxiliary prefixes that inherit the routing information of th original LPM (e.g., B) and place them at the locations where the binary search operations can find them.

  6. Proposed Binary Search for Prefixes(3/6) • We use a two-step method to construct the expansion list consisting of the sorted original and auxiliary prefixes. • First : To construct the hierarchical list.

  7. Proposed Binary Search for Prefixes(4/6) • Second : Called the Expansion_traversal() function.

  8. Proposed Binary Search for Prefixes(5/6) • Ex : B1 < D < B2 < C < B3 B1 = LCA( Min (B), D ), B2 = LCA( D, C), B3 = LCA( C, Max (B) ). • The worst-case number of prefixes in the expansion list is less than 2N for a routing table of N prefixes.

  9. Proposed Binary Search for Prefixes(6/6) • The binary search algorithm on the expansion list is illustrated as follow.

  10. Discuss(1/2) • The differences between BPS and BRS[15]: • Each prefix is identified as an individual entity instead of as the two endpoints for a range in BRS. • Only one port information is associated with each prefix in BPS while two ports such as “> ” and “=” ports are associated with each endpoint in BRS. • Unlike BRS, the interval not covered by any original prefix will not be stored in the expansion list of BPS. • Therefore, the size of the expansion list in BPS will be smaller than the size of the endpoint list in BRS.

  11. Discuss(2/2)

  12. Simple k-Bit Segmentation Table • This k-bit segmentation table divides the W-bit address space into 2k segments of 2W-k addresses. • Each element in k-bit segmentation table contains two fields, namely, the default port of the segment and the pointer. • When the update operations are needed, each element needs one more field, called the enclosure list. The port of the longest prefix in the enclosure list is stored in the default port field of the segment.

  13. k-Bit Segmentation Table and k_Set(1/2) • The original prefixes of lengths shorter than k bits are not duplicated in the enclosure list of the k-bit segmentation table. Instead, they are placed in an additional subset, called k_Set. • The expansion list constructed from the prefixes in k_Set is also needed. • Since either the segment size or k_Set size is much smaller than the original prefix set, the update performance will be greatly improved.

  14. k-Bit Segmentation Table and k_Set(2/2) • We can reuse the idea of the segmentation table to further reduce the search space in the k_Set. • Since there is no prefix of length shorter than 8 in the real routing tables, the best choice of l is 8.

  15. Simple k_Set • In this approach, the k-bit segmentation table does not physically exist. • The original prefixes of lengths shorter than k are placed into the k_Set.Other prefixes are placed into a single subset called the main_Set.

  16. Proposed Binary Search for Ranges(1/3) • How to define the endpoints of a range has a strong relationship to BRS performance. • In this paper, we propose a BRS based on a different endpoint definition (called BRS_Int) as in [4]. Where each new endpoint is associated with only one port.

  17. Proposed Binary Search for Ranges(2/3) • Definition 4: The two integer endpoints of a range [L,U] are defined as L - 1 and U when L != 0, but only one endpoint U is defined when L = 0. → • Basically, the search determines two cases where Dst <= E[0].endpoint(matched E[0].port) and E[i].endpoint < Dst < E[i+1].endpoint, for i > 0 (matched E[i+1].port).

  18. Proposed Binary Search for Ranges(3/3)

  19. Simple k-Bit Segmentation Table • An array of 2k elements is used as the k-bit segmentation table. • If a range overlaps with any part of the address space of a segment, it is stored in the range subset of that segment. • For each nonempty segment, the proposed BRS (BRS_Int) is performed.

  20. k-Bit Segmentation Table and k_Set • The range overlapped with at least three segments is placed into the k_Set; otherwise, it will be placed into the segments with which it overlaps. • The update process for a range R is limited to the segment that completely covers R, the segments partially overlapped with R, or the k_Set.

  21. Simple k_Set • The k-bit segmentation table does not physically exist. • The ranges that completely cover any segment or the ranges that overlap with at most two segmentsare placed into the k_Set. Other ranges are placed into the main_Set.

  22. Outline • One-Dimensional Packet Classification • Multidimensional Packet Classification • Performance Evaluation

  23. Multidimensional Packet Classification • 1.Hierarchical Expansion List • 2. Optimizations • List Sharing • Sequential Search • Hierarchical k-Bit Segmentation Table • d-Dimensional k1 x … x kd -Bit Segmentation Table • 3. Complexity

  24. Hierarchical Expansion List(1/4) • The basic data structure proposed in this paper for the multidimensional PC is a hierarchical expansion list of BPS and BRS _Int. • The hierarchical data structure is built as follows: • 1. Build the F1 hierarchical list based on the F1 field values of the rules.

  25. Hierarchical Expansion List(1/4) • 2. Push all subrules (F2 , . . . , Fd) associated with the elements of F1 hierarchical list in higher levels to their children in lower levels. We call this operation the rule pushing. • →

  26. Hierarchical Expansion List(3/4) • 3. Perform an expansion traversal in the F1 hierarchical list to construct the F1 expansion list. Now, each element of the F1 expansion list contains a number of (d-1) -dimensional subrules (F2 , . . . , Fd) . • 4. Continue steps 1, 2, and 3 for each dimension except for the rule pushing operation (step 2) which is not required for the last dimension.

  27. Hierarchical Expansion List(4/4) • The complete multidimensional packet classification algorithm Proposed_PC_Algorithm() is illustrated as follow: • The output of Proposed_PC_Algorithm() is a set of matched rules.

  28. List Sharing and Sequential Search • List sharing • Sequential Search If the number of subrules left to be matched in a node of the hierarchical list is less than a predefined threshold, it is reasonable to perform a sequential search

  29. Hierarchical k-Bit Segmentation Table (1/4) • Assume k=2, We first construct the F1 expansion list. • We have two options to construct the F2 expansion lists: with or without rule duplication.

  30. Hierarchical k-Bit Segmentation Table (2/4) • Option with rule duplication • If any rule in k_Set covers a rule in main_Set, its (d-1) -dimensional subrule is duplicated in the main_Set.

  31. Hierarchical k-Bit Segmentation Table (3/4) • Option without rule duplication • As a result, the (d-1) -dimensional subrule set pointed to by any element in the F1 expansion list becomes smaller than the original one. • However, we need to search both the main_Set and the k_Set in each level of the hierarchical expansion lists. The search speed may be worse than the original one. • if the depth of the hierarchical expansion list is not high, this approach may be a good choice.

  32. Hierarchical k-Bit Segmentation Table (4/4) • Selecting the dimension order • The performance will be different if the dimension order used by the proposed hierarchical scheme is different. • We use the following heuristics to select the best dimension order. Factor1: F1_size is the size of the F1 expansion list. Factor2: max_F2_size is the size of the largest F2 expansion list. • We select the dimension such that the sum of F1_size and max_F2_size is minimal. • Based on our experiments, the memory sizes are much different if the dimension order is different, but the search performance has no significant difference.

  33. d-Dimensional k1 x … x kd -Bit Segmentation Table(1/5) • In the real 5D classifier, a 2D k1 x k2 -bit segmentation table may have been sufficient to divide the total address space into smaller rectangles. • In the proposed 2D k1 x k2 -bit segmentation table, we have four kinds of rule subsets: k1k2_Set, k1_Set, k2_Set, and segment Si,j for i = 0 to 2k1-1 and j = 0 to 2k2-1.

  34. d-Dimensional k1 x … x kd -Bit Segmentation Table(2/5) • Assume that a rule R covers the area of [X1 x X2] x [Y1 x Y2]. Then we defined: thus (i2 –i1 +1) and (j2 – j1 +1) are the number of segments that covered by R in F1 and in F2.

  35. d-Dimensional k1 x … x kd -Bit Segmentation Table(3/5) • Rule R is duplicated in the k1k2_Set, k1_Set, k2_Set, or segments based on the rule placement algorithm along with two parameters c1 and c2 as follow: • 1. If (i2 –i1 +1 > c1) and (j2 – j1 +1 > c2), then R is put in the k1k2_Set. • 2. If (i2 – i1 + 1 <= c1 x c2) and (j2 – j1 = 0), then R is put in Si,j1 for i = i2, … , i1. Otherwise, if (i2 – i1 + 1 > c1) and (j2 – j1 + 1 <= c2), then R is put in k1_Setj for j = j2, … , j1.

  36. d-Dimensional k1 x … x kd -Bit Segmentation Table(4/5) • 3. If (i2 – i1 + 1 = 0) and (j2 – j1 + 1 = 0) , then R is put in Si1,j for j = j2, … , j1. Otherwise, if (i2 – i1 + 1 <= c1) and (j2 – j1 + 1 > c2),then R is put in k2_Seti for i = i2, … , i1. • 4. If (i2 –i1 +1 <= c1)and (j2 – j1 + 1 <= c2), then R is put in Si,j for i = i2, … , i1 and j = j2, … , j1.

  37. d-Dimensional k1 x … x kd -Bit Segmentation Table(5/5) • Further improve: • We record the highest priority values of k1_Set, k2_Set, and k1k2_Set independently. • After finding the matched rule with the highest priority value pri in Si, j, if pri is higher than the highest priority among the rules in other subsets, we no longer need to search other subsets.

  38. Complexity • We have shown that there are at most 2N -1 elements in the F1 expansion list in [3]. Thus, the worst-case space complexity is S(N, d) = O(Nd). • The worst-case time complexity of a search operation is O(d x log N).

  39. Outline • One-Dimensional Packet Classification • Multidimensional Packet Classification • Performance Evaluation

  40. Notation • Scheme H • The basic hierarchical expansion list. • Scheme H_k(k1, k2) • The hierarchical expansion list optimized by the simple k_Set approach without rule duplication. • Scheme H_2k(k1, k2, c1, c2) • The hierarchical expansion list optimized by a 2D k x k2 -bit segmentation table of the first two prefix fields. • Scheme H_2k_opt(k1, k2, c1, c2) • The improved version of H_2k(k1, k2, c1, c2) optimized by the highest priority arrangements.

  41. Prefix length distribution

  42. Performance Evaluation(1/6)

  43. Performance Evaluation(2/6)

  44. Performance Evaluation(3/6)

  45. Performance Evaluation(4/6)

  46. Performance Evaluation(5/6)

  47. Performance Evaluation(6/6)

More Related