Computer ScienceEngineering

Xiang Chen, Wenbin Zhang, Xi Sun, Hongyan Liu, Jianshan Zhang, Qun Huang, Dong Zhang, Haifeng Zhou, Xuan Liu, Chunming Wu

2024.10.1IEEE-ACM TRANSACTIONS ON NETWORKING

DOI: 10.1109/tnet.2024.3413530

tlooto Summary

Melody is a new framework that reuses PHV words for as many fields as possible to achieve resource-efficient PHV encoding and provides a Greedy-based heuristic, which quickly solves PHV encoding and returns near-optimal results.

Abstract

The programmable switch offers a limited capacity of packet header vector (PHV) words that store packet header fields and metadata fields defined by network functions. However, existing switch compilers employ inefficient strategies of encoding fields on PHV words. Their encoding wastes scarce PHV words and may result in failures when deploying network functions. In this paper, we propose Melody, a new framework that reuses PHV words for as many fields as possible to achieve resource-efficient PHV encoding. Melody offers a field analyzer and an optimization framework. The analyzer identifies which fields can reuse PHV words while preserving the original packet processing logic. The framework integrates analysis results into its encoding to offer the resource-optimal decisions. Also, to achieve timeliness at runtime, it provides a Greedy-based heuristic, which quickly solves PHV encoding and returns near-optimal results. We evaluate Melody with production-scale network functions. Our results show that Melody reduces the consumption of PHV words by up to 85%.

Citation format

CHEN, Xiang, et al. Resource-efficient and timely packet header vector (PHV) encoding on programmable switches. IEEE-ACM TRANSACTIONS ON NETWORKING, 2024, 32: 4191–4206.