T-Cache: Efficient Policy-Based Forwarding Using Small TCAM
Ying Wan,Haoyu Song,Yang Xu,Yilun Wang,Tian Pan,Chuwen Zhang,Yi Wang,Bin Liu
DOI: https://doi.org/10.1109/tnet.2021.3098320
2021-01-01
IEEE/ACM Transactions on Networking
Abstract:Ternary Content Addressable Memory (TCAM) is widely used by modern routers and switches to support policy-based forwarding due to its incomparable lookup speed and flexible matching patterns. However, the limited TCAM capacity does not scale with the ever-increasing rule table size due to the high hardware cost and high power consumption. At present, using TCAM just as a rule cache is an appealing solution, but one must resolve several tricky issues including the rule dependency and the associated TCAM updates. In this paper, we propose a new approach which can generate dependency-free rules to cache. By removing the rule dependency, the complex TCAM update problem also disappears. We provide the complete T-cache system design including slow path processing and cache replacement, and implement a T-cache prototype on Barefoot Tofino switches. We conduct comprehensive software simulations and hardware experiments based on real-world and synthesized rule tables and packet traces to show that T-cache is efficient and robust for network traffic in various scenarios.