Presentation is loading. Please wait.

Presentation is loading. Please wait.

DRES: Dynamic Range Encoding Scheme for TCAM Coprocessors 2008 YU-ANTL Lab Seminar June 11, 2008 JeongKi Park Advanced Networking Technology Lab. (YU-ANTL)

Similar presentations


Presentation on theme: "DRES: Dynamic Range Encoding Scheme for TCAM Coprocessors 2008 YU-ANTL Lab Seminar June 11, 2008 JeongKi Park Advanced Networking Technology Lab. (YU-ANTL)"— Presentation transcript:

1 DRES: Dynamic Range Encoding Scheme for TCAM Coprocessors 2008 YU-ANTL Lab Seminar June 11, 2008 JeongKi Park Advanced Networking Technology Lab. (YU-ANTL) Dept. of Information & Comm. Eng, Graduate School, Yeungnam University, KOREA (Tel : +82-53-810-2497; Fax : +82-53-810-4742 http://antl.yu.ac.kr/http://antl.yu.ac.kr/; E-mail : jk21p@ynu.ac.kr) Hao Che, Zhijun Wang, Kai Zheng, Bin Liu IEEE TRANSACTIONS ON COMPUTERS, VOL52, NO.7 JULY 2008

2 Advanced Networking Tech. Lab. Yeungnam University (YU-ANTL) YU-ANTL Lab. Seminar JeongKi Park 2 Outline  Introduction  Rule Implementation in TCAM  Range Encoding Structures of Encoded Rule and Encoded Search Key TCAM-Based Search Key Encoding Process Dynamic Range Selection Algorithm Code Vector and Index Vector Encoding Algorithms  Encoded Range Update Process Encoding a Newly Selected Range & Releasing Encoded Ranges  Performance Evaluation Based on Real-world Databases  Analytical Performance Evaluation  Conclusion and Future Work

3 Advanced Networking Tech. Lab. Yeungnam University (YU-ANTL) YU-ANTL Lab. Seminar JeongKi Park 3 Introduction (1)  Fast packet classification algorithms for Longest Prefix Matching and general policy/firewall filtering Most approaches cannot provide lookup performance matching multigigabit line rate  TCAM coprocessor works as a look aside processor for packet classification NPU generates a search key TCAM finds a matched rule in a small constant number of clock cycle  Range matching low storage efficiency Need to do a range preprocessing/encoding (bitmapping)  Rule encoding  Search key encoding  Range selection algorithm  Database update algorithm

4 Advanced Networking Tech. Lab. Yeungnam University (YU-ANTL) YU-ANTL Lab. Seminar JeongKi Park 4 Introduction (2)  Range encoding scheme Top-down approach  Is designed the most efficient rule encoding  Subjects to hardware constraints of the existing TCAM-based packet classification solutions Bottom-up approach  May not offer the highest encoding gain  But it will work with only software upgrades  Dynamic Range Encoding Scheme Bottom-up approach with improving the TCAM storage efficiency Comprehensive solution which include all four algorithms Encoded rule structure allows any subset of ranges in any subset of rule fields to be encoded General range encoding framework that allows any existing range encoding algorithms to be incorporated for range encoding

5 Advanced Networking Tech. Lab. Yeungnam University (YU-ANTL) YU-ANTL Lab. Seminar JeongKi Park 5 Rule Implementation in TCAM  TCAM coprocessor has a TCAM and an associated memory (SRAM) TCAM is organized in slots (64,72,128,192,256 bits) A bit in each slot can take one of three values: 0, 1, *(don’t care)  When packet comes, the NPU generates a search key based on the packet header information and passes it to the TCAM coprocessor  The rule PF typically use five-tuple 104 bit(for IPv4)

6 Advanced Networking Tech. Lab. Yeungnam University (YU-ANTL) YU-ANTL Lab. Seminar JeongKi Park 6 Rule Implementation in TCAM  Example,

7 Advanced Networking Tech. Lab. Yeungnam University (YU-ANTL) YU-ANTL Lab. Seminar JeongKi Park 7 Structures of Encoded Rule and Encoded Search Key  Hybrid encoding approach Retains all of the fields in a rule and appends a sequence of code bits of length c t, called the code vector or index vector, to the rule to form an encoded rule Use some free bits for vectors

8 Advanced Networking Tech. Lab. Yeungnam University (YU-ANTL) YU-ANTL Lab. Seminar JeongKi Park 8 TCAM-Based Search Key Encoding Process  The search key encoding process Assume that m k ranges from the kth rule filed in a rule database are selected for encoding. Then, K search key fields matching against the corresponding K range tables must be done to generate an index vector and, hence, an encoded search key Must be performed at wire speed by the NPU  In DRES, it uses the TCAM coprocessor itself for sequential search key encoding One encoded rule table K range tables Process  The NPU updates the index vector by performing an OR operation between the index vector and the returned intermediate index vector  The encoded search key is formed by appending the final index vector to the original search key  This encoded search key is used to match against the encoded rule table

9 Advanced Networking Tech. Lab. Yeungnam University (YU-ANTL) YU-ANTL Lab. Seminar JeongKi Park 9 TCAM-Based Search Key Encoding Process  This scheme may have heavy use of the TCAM coprocessor It allows 4.28 TCAM lookups per packet  TCAM 133 MHz (133 million lookups per second)  31.3 million packets at a 10 Gbps line rate in the worst case For 2.5Gbps line rate, each packet is allowed to perform 17 lookups Encoding more fields leads to heavier TCAM access contention but better TCAM storage efficiency The ability of DRES to allow any subset of rule fields to be selected for encoding makes it possible for DRES to fully exploit this trade-off

10 Advanced Networking Tech. Lab. Yeungnam University (YU-ANTL) YU-ANTL Lab. Seminar JeongKi Park 10 Dynamic Range Selection Algorithm S i is the number of subranges needed to exactly implement range R i in a TCAM E i is the number of rule entries to implement all of the rules that contain range Ri G i is the encoding gain for R i, defined as the number of rule entries that can be eliminated if R i is encoded {256 – 512} {768 – 2047} {6000 – 6064} { >1023} {512 – 1536} { >1023} {256 – 512}

11 Advanced Networking Tech. Lab. Yeungnam University (YU-ANTL) YU-ANTL Lab. Seminar JeongKi Park 11 Code Vector and Index Vector Encoding Algorithms  P 2 C algorithm is most efficient N ranges to be encoded by using log 2 (N+1)[best cast] ~ N[worse case] bits But it can be shown that the dynamic range selection problem can be translated in polynomial time to a weighted knapsack problem, which is NP-complete  Bit-map intersection algorithm for DRES For example, L3 has R6 in its source port and R2 in its destination port  *1***1***

12 Advanced Networking Tech. Lab. Yeungnam University (YU-ANTL) YU-ANTL Lab. Seminar JeongKi Park 12 Encoded Range Update Process  New rules may be added and old rule may be deleted from time to time  This paper propose a lock-free encoded range update algorithm Allow the encoded range update and the search key encoding/PF table lookup processes to occur simultaneously without impacting the lookup performance  Updating a TCAM database without TCAM locking may generate An erroneous lookup may occur if a TCAM rule gets a match while the rule or its corresponding action is partially updated An inconsistent lookup means that a search key does not match the best matched rule. An inconsistent lookup may occur when a match takes place in the middle of a database update process and there is no guarantee of table consistency until the process finishes  Write process using a valid bit field in each TCAM slot 1) inactivate the rule 2) write the rule/action 3) activate the rule again  Move process that operation to move a rule-action pair to a new TCAM-associated memory location 1) using a write process to write the pair to the new location 2) inactivating the rule at the old location

13 Advanced Networking Tech. Lab. Yeungnam University (YU-ANTL) YU-ANTL Lab. Seminar JeongKi Park 13 Encoding a Newly Selected Range & Releasing Encoded Ranges

14 Advanced Networking Tech. Lab. Yeungnam University (YU-ANTL) YU-ANTL Lab. Seminar JeongKi Park 14 Performance Evaluation Based on Real- world Databases  Four real-world PF databases  Storage expansion ratio = the # of rule entries / the # of rules in a TCAM  FSP(the range frequency in the source port)  FDP(the range frequency in the destination port)  TF(the range frequency in the both port)  NSUB(the number of subranges)  DB1 and DB2 have RN1, RN4 in both source and destination ports  DB3 has RN1, RN4, RN6 in source port and RN1, RN7, RN8 in destination ports  DB4 has RN1, RN2, RN3 in both ports and RN10 in the destination ports

15 Advanced Networking Tech. Lab. Yeungnam University (YU-ANTL) YU-ANTL Lab. Seminar JeongKi Park 15 Performance Evaluation Based on Real- world Databases  Apply DRES to all four DB for a 64-bit slot TCAM Five-tuple rule : 104 bits Each rule entry take two slots : 128 bits 24 free bits which is much larger than 7, MAX # of unique ranges

16 Advanced Networking Tech. Lab. Yeungnam University (YU-ANTL) YU-ANTL Lab. Seminar JeongKi Park 16 Analytical Performance Evaluation  Use a probabilistic model to analyze the performance of DRES in a wide range of parameters

17 Advanced Networking Tech. Lab. Yeungnam University (YU-ANTL) YU-ANTL Lab. Seminar JeongKi Park 17 Analytical Performance Evaluation  The popularity distribution closely follows a Zipf-like distribution, with z=3 z is Zipf coefficient is the rank of the jth range is proportional to the popularity rank of range j c is a normalization factor

18 Advanced Networking Tech. Lab. Yeungnam University (YU-ANTL) YU-ANTL Lab. Seminar JeongKi Park 18 Impact of the Number of Unique Ranges

19 Advanced Networking Tech. Lab. Yeungnam University (YU-ANTL) YU-ANTL Lab. Seminar JeongKi Park 19 Conclusion  DRES is proposed to improve the TCAM storage efficiency in support of range matching Bottom-up approach Work its TCAM coprocessor with only a software upgrade TCAM storage expansion is reduced from 6.2 to as low as 1.23  DRES is its ability to have full control over the encoded rule size Exploit the TCAM structure for maximizing the encoding gains Adopts the bit-map intersection encoding scheme A range selection algorithm Uses a lock-free encoded range update algorithm

20 Advanced Networking Tech. Lab. Yeungnam University (YU-ANTL) YU-ANTL Lab. Seminar JeongKi Park 20 Reference [1] Hao Che, Zhijun Wang, Kai Zheng, Bin Liu, “DRES: Dynamic Range Encoding Scheme for TCAM Coprocessors,” IEEE Transactions On Computers, Vol.57, No.7, July 2008.


Download ppt "DRES: Dynamic Range Encoding Scheme for TCAM Coprocessors 2008 YU-ANTL Lab Seminar June 11, 2008 JeongKi Park Advanced Networking Technology Lab. (YU-ANTL)"

Similar presentations


Ads by Google