Programming Network Stack for Middleboxes with Rubik
summary
Rubik is a Python-based DSL plus compiler that generates optimized C network stacks for middleboxes, using a domain-specific IR to cluster and eliminate redundant packet-processing logic and enable fast paths. Authors implement 12 real protocol stacks and claim 250 lines for a TCP/IP stack, 2 orders magnitude less code compared to hand-written versions, and performance gains of 30%+ throughput with some stacks hitting 100 Gbps.
AI-written summary · about
chapters (20)
- 0:00Start
- 0:30Middleboxes are indispensable
- 1:06Components of a Middlebox
- 1:32Coding Efforts for Each Component
- 2:03Reduce Coding Efforts in Network Stack
- 2:28Diverse Stack Implementation
- 3:26A Seemingly Generalized Workflow
- 4:37Challenges of Designing a DSL for Middlebox Stack
- 5:59Introducing Rubik
- 6:28A Walk-through Example
- 6:40Write an IP parser with Rubik
- 7:31Compose ETH-IP/ARP Stack
- 8:05A Domain-Specific Compiler
- 8:26Intermediate Representation for IP Parser
- 8:50Optimize a Fast Path Automatically
- 10:06Domain-Specific Optimizations
- 10:29Case Study: Parsers
- 10:40Case Study: Stacks
- 10:55Performance Evaluation: Other Stacks
- 11:07Conclusion
related talks
24mNetBlocks: Staging Layouts for High-Performance Custom Host Network Stacks
50mHigh Performance Network Programming in Rust
18miStack: A General and Stateful Name-based Protocol Stack for Named Data Networking
01h 01mStructured Networking
01h 08mThe Network is the Computer: A Programming Language Perspective
32mTracing the Linux networking stack with Retis
28mCreating Memory Efficient and High Performance IP Stack for Zephyr OS
24mCan a User-Space Protocol Stack Balance High Performance and Generality? Our Answer: Both.
