Download presentation
Presentation is loading. Please wait.
Published byTamsyn Sanders Modified over 9 years ago
1
Scalable High Speed IP Routing Lookups Scalable High Speed IP Routing Lookups Authors: M. Waldvogel, G. Varghese, J. Turner, B. Plattner Presenter: Zhqi Qiu
2
Outline Routing and the BMP (Best Matching Prefix) problem Basic scheme: binary search of hash tables Refinements: asymmetric trees, mutated binary search and ropes Implementation: building the tree Performance and comparison study
3
Introduction Increases in Internet traffic demands: link speed, router data throughput, packet forward rate Packet forwarding rate becomes bottleneck Address lookup: main step in packet forwarding Need efficient Best Prefix Match algorithm
4
More about BMP Classless Inter-Domain Routing (CIDR) - cope with routing table growth Aggregation results in address prefix list in routing tables Packets forwarded according to Best Matching Prefix Goal: use hashing to find BMP
5
Outline Routing and the BMP (Best Matching Prefix) problem Basic scheme: binary search of hash tables Refinements: asymmetric trees and ropes Implementation: building the tree Performance and comparison study
6
Basic Scheme Hash table organized by prefix length Markers needed
7
Marker Management Reducing marker storage: markers only needed in levels visited by binary search when looking for P E. g. : In table of 8 levels: a prefix with length of 7 [111] needs markers in level 4 and 6 a prefix with length of 3 [11] needs markers in level 2
8
False Markers What if table entries are: P1=1, P2=00, P3=110 in the previous example? Solution: to avoid backtracking, record current best matching prefix of marker M in M.bmp
9
Basic Algorithm Initialize range R = array L Initialize BMP to be null string While R not empty I = middle level in range R D’ = D(L[i].length) M = Search(D’, L[i].hash) If M is nil Then set R = upper R Elseif M is a prefix & not a marker Then BMP = M.bmp; break Else { BMP = M.bmp; R = lower R} Endif Endwhile
10
Outline Routing and the BMP (Best Matching Prefix) problem Basic scheme: binary search of hash tables Refinements: asymmetric trees and ropes Implementation: building the tree Performance and comparison study
11
Algorithm Refinements To optimize, need to exploit deeper structure in routing table Simplest improvement: Search only non-empty tries
12
Asymmetric Binary Search Try to search the most promising trie first Example: Maximize table entries while keeping tree balance
13
Mutating Binary Search The number of distinct prefix lengths rarely exceeds 12 Every match with some marker X means that we need only search among the set of prefixes for which X is a prefix
15
Potential Disadvantages Pre-computing optimal trees increases insertion time Storage of binary trees for each prefix enormous Storage problem solved with “rope” data structure Rope maximum length: log 2 W pointers
16
Rope: Encoded Trees Only need to store the sequence of levels which binary search on a given subtrie will follow on repeated failures to find a match e.g.: Rope 1 contains 16, 8, 4, 2, 1 Rope algorithm: a prefix not a marker: end of rope a prefix and a marker: X.bmp = X
18
Rope Search Initialize Rope R = default search sequence Initialize BMP = null string While R not empty i = first pointer of R D’ = D(L[i].length) M = Search(D’, L[i].hash) If M is success Then BMP = M.bmp; R = M.rope Endif Endwhile
19
Building Rope Search Pass 1: builds a conventional trie Pass 2: all prefixes inserted into hash tables, starting with shortest prefix Batch insertions and deletions into the table as these operations are expensive.
20
Outline Routing and the BMP (Best Matching Prefix) problem Basic scheme: binary search of hash tables Refinements: asymmetric trees and ropes Implementation: building the tree Performance and comparison study
21
Existing Approaches Modification of exact matching:log 2 2N Trie based: BDS radix trie O(W 2 ) Hardware: parallelism, CAM expensive Protocol based: IP/tag switching, still need some IP lookups Caching: CAM (Content Addressable Memory)
22
Complexity Comparison
23
Performance Comparison
24
Conclusion Intellectual contribution: markers and pre-computation ensure log time in worst-case Solution scalable and can be implemented in software efficiently Future work: choice of balancing function and faster insertion algorithms
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.