1 / 31

AN ON-CHIP IP ADDRESS LOOKUP ALGORITHM

This paper presents a hardware design reference model for an on-chip IP address lookup algorithm, proposing a scheme with compressed endpoints and shared pointers to build the tree, resulting in improved performance. Published in IEEE Transactions on Computers, 2005.

hodgesj
Download Presentation

AN ON-CHIP IP ADDRESS LOOKUP ALGORITHM

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. AN ON-CHIP IP ADDRESS LOOKUP ALGORITHM Author: Xuehong Sun and Yiqiang Q. Zhao Publisher/Conf.: IEEE TRANSACTIONS ON COMPUTERS,2005 Speaker: Han-Jhen Guo Date: 2008.11.19

  2. OUTLINE • Hardware Design Reference Model • Convert Longest Prefix Match To Range Search Problem • Proposed Scheme • Compressed Endpoints • Shared Pointers • Build The Tree (Bottom Up) • Performance

  3. HARDWARE DESIGN REFERENCE MODEL chip (internal) mem. acess time = 1.25ns (several times faster than DRAM) external 13 bits Next Hop Information des. IP address

  4. CONVERT LONGEST PREFIX MATCH TO RANGE SEARCH PROBLEM (1/4) • Definition • [b, e) is defined as the range of the prefix P • b and e are defined as the left endpoint and right endpoint of prefix P

  5. CONVERT LONGEST PREFIX MATCH TO RANGE SEARCH PROBLEM (2/4) Routing table (len. = 6) Range representation

  6. CONVERT LONGEST PREFIX MATCH TO RANGE SEARCH PROBLEM (3/4) • Port merging C A B A C C D C A C A A C A B A C D C A C A

  7. CONVERT LONGEST PREFIX MATCH TO RANGE SEARCH PROBLEM (4/4) • The IP address lookup problem is converted into the predecessor finding problem in a priority queue • given a set of sorted integers S and an integer i, find an integer e in S such that e is the biggest one which is less than or equal to i search 39

  8. PROPOSED SCHEME- COMPRESSED ENDPOINTS (1/4) • eg. real-life IPv4 endpoints trailing zeros common leading bits (CLB) keys

  9. PROPOSED SCHEME- COMPRESSED ENDPOINTS (2/4) • Data structure of one word in on-chip memory (row data structure of a node of the tree) 1 4 5 5 144 - (1 + 4 + 5 + 5 + 20) = 109 20 inter. node: index of next lv. node leaf node: index of port info.

  10. PROPOSED SCHEME- COMPRESSED ENDPOINTS (3/4) • Set up the field of common leading bits • to calculate the number of common leading bits of the smallest and the biggest endpoints in the group • O(2) • Set up the field of trailing zeros • the first endpoint are counted and recorded as the candidate number of common trailing zeros • the trailing zeros of the next endpoint are counted • if the number of the trailing zeros of the next endpoint is smaller than the candidate number, the candidate number is changed to the smaller one • otherwise the candidate number is unchanged • O(N), N is # of nodes in a group

  11. PROPOSED SCHEME- COMPRESSED ENDPOINTS (4/4) • eg. real-life IPv4 endpoints trailing zeros common leading bits (CLB) keys

  12. PROPOSED SCHEME- SHARED POINTERS • eg.(apply to B-tree) 0 1 2 3 4

  13. PROPOSED SCHEME- BUILD THE TREE (BOTTOM UP) • Given a set of sorted endpoints, we assign endpoints to leaf nodes and then to the next highest level until the root level • Select the first four endpoints as a group and calculate tb (= the total bits of the compressed keys) • tb = 109 → store these four endpoints a word (group) • tb > 109 → store first three endpoints a word • tb < 109 → check if can store (4 + 1) endpoints...

  14. PROPOSED SCHEME- BUILD THE TREE (BOTTOM UP) a • Variant 1 • grouping • a~d: 13*4=52 < 109 • a~e: 14*5=70 < 109 • … • a~g: 14*7=98 < 109 • a~h: 14*8=112 > 109 → {a,b,c,…,g} is a leaf, then h should be higher lv. • i~j: … b c d e f g h i j k L m

  15. PROPOSED SCHEME- BUILD THE TREE (BOTTOM UP) a • Variant 1 • after grouping b c d e f g h i j k L m

  16. PROPOSED SCHEME- BUILD THE TREE (BOTTOM UP) a • Variant 1 • eg. mistaking CLB b c d 10011111 F F 00 e f g h 10011111 F F 0 i j k L 1111 F F (EORROR!) m

  17. PROPOSED SCHEME- BUILD THE TREE (BOTTOM UP) a • Variant 1 • compute CLB and trailing 0s b c d e f 5 g h h i 1 j k L m

  18. PROPOSED SCHEME- BUILD THE TREE (BOTTOM UP) a • Variant 1 • searching b c d 10011111 F F 00 e f g h 10011111 F F 0 i 0011111 F F j k L m

  19. PROPOSED SCHEME- BUILD THE TREE (BOTTOM UP) a • Variant 2 • grouping • a~d: 13*4=52 < 109 • a~e: 14*5=70 < 109 • … • a~g: 14*7=98 < 109 • a~h: 14*8=112 > 109 → {a,b,c,…,g} is a leaf • h~k: … b c d e f g h i j k L m

  20. PROPOSED SCHEME- BUILD THE TREE (BOTTOM UP) a • Variant 2 • after grouping b c d e f g h i j k L m

  21. PROPOSED SCHEME- BUILD THE TREE (BOTTOM UP) n1 a • Variant 2 • creating new endpoints to next higher lv. b c d e f g n2 CLB(n1, n2) h i j k CLB(n2, n3) n3 L m CLB(n3, m)

  22. PROPOSED SCHEME- BUILD THE TREE (BOTTOM UP) n1 a • Variant 2 • searching b c d 10011111 F 1111 e f g n2 h 10011111 F F 0 i 10011111 F 1111 j k n3 L m

  23. PROPOSED SCHEME- BUILD THE TREE (BOTTOM UP) • Variant 3 • apply variant 1 to lower levels apply variant 2 to higher levels • in experiment of perfomance • variant 1 are applied to leaflevels variant 2 are applied to other higherlevels

  24. PROPOSED SCHEME- BUILD THE TREE (BOTTOM UP) • Variant 4 • divides the endpoints into groups according to their leading bits • according to groups, respective tree structure is created using techniques described in this paper (variant 1 or 2)

  25. PERFORMANCE • Port merge effect (IPv4)

  26. PERFORMANCE • Comparisons on variants (width = 144) (IPv4) • variant 3 is well balanced min mem. req. max mem. access time min mem. access time max mem. req.

  27. PERFORMANCE • Implement with variant 3 • ME ratio = mem. req. in bits / # of prefixes • Arityof a node = the # of subtrees of the node • memory access times = logArity (table_size) Results of IPv6 Using 168 Bits Memory Width Results of IPv4 Using 144 Bits Memory Width probably due to a high percentage (above 70 percent) of length 48 prefixes

  28. PERFORMANCE • Memory size for IPv4 as a function of table size with different memory widths better choices

  29. PERFORMANCE • Memory size for IPv6 as a function of table size with different memory widths better choices

  30. PERFORMANCE • Number of Memory Accesses for IPv4 and IPv6 as a Function of Table Size and Memory Width IPv4 both are NOT sensitive to table size IPv6

  31. Thanks for your listening!

More Related