Skip to main content
QUICK REVIEW

[Paper Review] Programmable Switch as a Parallel Computing Device

Li Chen, Ge Chen|arXiv (Cornell University)|Mar 5, 2018
Software-Defined Networks and 5GComputer Science10 references9 citations
TL;DR

This paper proposes p4mr, a parallel programming framework that offloads Map-Reduce workloads to programmable switches for in-transit data processing, achieving up to 20× speedup over CPU-based execution. By modeling data plane computation costs and using a P4-based compiler stack, the framework enables efficient distribution of computation across a network of switches via dependency-aware label placement and packet-level execution.

ABSTRACT

Modern switches have packet processing capacity of up to multi-tera bits per second, and they are also becoming more and more programmable. We seek to understand whether the programmability can translate packet processing capacity to computational power for parallel computing applications. In this paper, we first develop a simple mathematical model to understand the costs and overheads of data plane computation. Then we validate the the performance benefits of offloading computation to network. Using experiments on real data center network, we finnd that offloading computation to the data plane results in up to 20x speed-up for a simple Map-Reduce application. Motivated by this, we propose a parallel programming framework, p4mr, to help users efficiently program multiple switches. We successfully build and test a prototype of p4mr on a simulated testbed.

Motivation & Objective

  • To investigate whether programmable switches can serve as parallel computing devices by leveraging their high packet processing capacity.
  • To address the challenge of offloading parallel workloads like Map-Reduce to the data plane while minimizing performance penalties.
  • To design a scalable programming framework that enables users to express and deploy distributed data plane computations across multiple switches.
  • To evaluate the feasibility and performance benefits of in-network computation using a simulated testbed with real-world workloads.

Proposed method

  • Developed a mathematical model to analyze the performance overhead of data plane computation, focusing on serialization and forwarding costs.
  • Designed a P4-based compiler stack using flex & bison to parse high-level p4mr code into an abstract syntax tree (AST), then convert it into a dependency-directed acyclic graph (DAG).
  • Implemented a greedy label placement algorithm to assign computation tasks (labels) to switches based on dependency and hop count minimization.
  • Defined a custom packet header format with fields for application ID, routing ID, collection ID, and data payload to support in-network computation and result aggregation.
  • Built a prototype in Mininet using P4 switches to simulate the execution of p4mr programs, including packet assembly and stateful variable updates.
  • Evaluated correctness through end-to-end testing by forwarding final results to a designated host for validation.

Experimental results

Research questions

  • RQ1What primitive computations can be efficiently implemented on programmable switches for parallel workloads?
  • RQ2What is the performance penalty of offloading computation to the data plane compared to traditional CPU-based execution?
  • RQ3How can multiple switches be programmed and coordinated to perform distributed data processing tasks in a scalable and efficient manner?
  • RQ4What are the key system design challenges in enabling general-purpose parallel computing on programmable switches?

Key findings

  • Offloading a simple Map-Reduce workload to the data plane resulted in up to 20× speedup compared to CPU-based execution, demonstrating significant performance benefits.
  • The proposed p4mr framework successfully compiled and executed a Word-Count-like workload on a simulated testbed using Mininet and P4 switches.
  • The dependency-aware label placement algorithm effectively minimized the average number of hops for data packets, improving overall performance.
  • The prototype correctly aggregated intermediate results using stateful variables in P4 switches and correctly delivered final results to the designated host.
  • The framework supports functional correctness of distributed computation in the data plane, though performance evaluation on real hardware remains future work.
  • The study identifies memory footprint and multi-job scheduling as critical challenges for production deployment of such systems.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.