Bypassing the Linux net stack with Go
summary
Claim: a normal Go process can read and write raw Ethernet frames and bypass the Linux network stack using XDP and eBPF. Implementation details: eBPF programs (written in C, verified then JIT-compiled) attach to XDP hooks; socket maps redirect frames into AF_XDP sockets; user memory (UMEM) is shared as descriptor rings per queue; code shows custom polling, per-queue goroutines for RX/TX, and a PPPoE proxy proving usefulness. Performance notes: NIC offload or driver XDP runs fastest, fallback hits kernel; hardware example 100 Gbps and up to 32 queues; key components AF_XDP sockets UMEM.
AI-written summary · about
