Lyra: A Cross-Platform Language and Compiler for Data Plane Programming on Heterogeneous ASICs

Programmable data plane has been moving towards deployments in data centers as mainstream vendors of switching ASICs enable programmability in their newly launched products, such as Broadcom's Trident-4, Intel/Barefoot's Tofino, and Cisco's Silicon One. However, current data plane programs are written in low-level, chip-specific languages (e.g., P4 and NPL) and thus tightly coupled to the chip-specific architecture. As a result, it is arduous and error-prone to develop, maintain, and composite data plane programs in production networks. This paper presents Lyra, the first cross-platform, high-level language & compiler system that aids the programmers in programming data planes efficiently. Lyra offers a one-big-pipeline abstraction that allows programmers to use simple statements to express their intent, without laboriously taking care of the details in hardware; Lyra also proposes a set of synthesis and optimization techniques to automatically compile this "big-pipeline" program into multiple pieces of runnable chip-specific code that can be launched directly on the individual programmable switches of the target network. We built and evaluated Lyra. Lyra not only generates runnable real-world programs (in both P4 and NPL), but also uses up to 87.5% fewer hardware resources and up to 78% fewer lines of code than human-written programs.

[1]  Jennifer Rexford,et al.  HULA: Scalable Load Balancing Using Programmable Data Planes , 2016, SOSR.

[2]  Nate Foster,et al.  NetKAT: semantic foundations for networks , 2014, POPL.

[3]  George Varghese,et al.  P4: programming protocol-independent packet processors , 2013, CCRV.

[4]  Taegyun Kim,et al.  Autogenerating Fast Packet-Processing Code Using Program Synthesis , 2019, HotNets.

[5]  Pavol Cerný,et al.  Event-driven network programming , 2015, PLDI.

[6]  Jianping Wu,et al.  HyperVDP: High-Performance Virtualization of the Programmable Data Plane , 2019, IEEE Journal on Selected Areas in Communications.

[7]  Anirudh Sivaraman,et al.  Language-Directed Hardware Design for Network Performance Monitoring , 2017, SIGCOMM.

[8]  Minlan Yu,et al.  SilkRoad: Making Stateful Layer-4 Load Balancing Fast and Cheap Using Switching ASICs , 2017, SIGCOMM.

[9]  George Varghese,et al.  Forwarding metamorphosis: fast programmable match-action processing in hardware for SDN , 2013, SIGCOMM.

[10]  T. S. Eugene Ng,et al.  Accelerated Service Chaining on a Single Switch ASIC , 2019, HotNets.

[11]  Anirudh Sivaraman,et al.  Network architecture in the age of programmability , 2020, Comput. Commun. Rev..

[12]  David Walker,et al.  A compiler and run-time system for network programming languages , 2012, POPL '12.

[13]  Yu Zhou,et al.  HyperV: A High Performance Hypervisor for Virtualization of the Programmable Data Plane , 2017, 2017 26th International Conference on Computer Communication and Networks (ICCCN).

[14]  Hong Liu,et al.  Jupiter Rising: A Decade of Clos Topologies and Centralized Control in Google's Datacenter Network , 2015, Comput. Commun. Rev..

[15]  Nate Foster,et al.  NetCache: Balancing Key-Value Stores with Fast In-Network Caching , 2017, SOSP.

[16]  Chengchen Hu,et al.  P4Visor: lightweight virtualization and composition primitives for building and testing modular programs , 2018, CoNEXT.

[17]  David Walker,et al.  SNAP: Stateful Network-Wide Abstractions for Packet Processing , 2015, SIGCOMM.

[18]  Nate Foster,et al.  Composing Dataplane Programs with μP4 , 2020, SIGCOMM.

[19]  Jitendra Padhye,et al.  CrystalNet: Faithfully Emulating Large Production Networks , 2017, SOSP.

[20]  David Walker,et al.  Frenetic: a network programming language , 2011, ICFP.

[21]  Walter Willinger,et al.  Sonata: query-driven streaming network telemetry , 2018, SIGCOMM.

[22]  Alvin Cheung,et al.  Packet Transactions: High-Level Programming for Line-Rate Switches , 2015, SIGCOMM.