论文标题
HXDP:FPGA NIC上有效的软件数据包处理
hXDP: Efficient Software Packet Processing on FPGA NICs
论文作者
论文摘要
NIC上的FPGA加速器可以从CPU卸载昂贵的数据包处理任务。但是,FPGA的资源有限,可能需要在不同的应用程序中共享,并且很难编程它们。 我们提供了一种解决方案,可以在FPGA上运行Linux的Express数据路径程序,同时仅使用可用硬件资源的一小部分,同时匹配高端CPU的性能。 EBPF的迭代执行模型不适合FPGA加速器。尽管如此,我们表明在针对专用的FPGA执行人时,可以压缩,并行或完全删除EBPF程序的许多说明,从而显着提高性能。我们利用它来设计HXDP,其中包括(i)优化兼容器,将EBPF字节在我们定义的扩展EBPF指令集架构中并行化并将EBPF字节码转换为扩展的EBPF指令集架构; a(ii)soft-cpu在FPGA上执行此类说明; (iii)基于FPGA的基础架构,可提供Linux内核中定义的XDP地图和辅助功能。 我们在FPGA NIC上实现HXDP,并评估它运行现实世界未修改的EBPF程序。我们的实现为156.25MHz,使用了大约15%的FPGA资源,并且可以动态加载程序。尽管有这些适度的要求,但它仍可以达到高端CPU核心的数据包处理吞吐量,并提供了较低的数据包转发延迟。
FPGA accelerators on the NIC enable the offloading of expensive packet processing tasks from the CPU. However, FPGAs have limited resources that may need to be shared among diverse applications, and programming them is difficult. We present a solution to run Linux's eXpress Data Path programs written in eBPF on FPGAs, using only a fraction of the available hardware resources while matching the performance of high-end CPUs. The iterative execution model of eBPF is not a good fit for FPGA accelerators. Nonetheless, we show that many of the instructions of an eBPF program can be compressed, parallelized or completely removed, when targeting a purpose-built FPGA executor, thereby significantly improving performance. We leverage that to design hXDP, which includes (i) an optimizing-compiler that parallelizes and translates eBPF bytecode to an extended eBPF Instruction-set Architecture defined by us; a (ii) soft-CPU to execute such instructions on FPGA; and (iii) an FPGA-based infrastructure to provide XDP's maps and helper functions as defined within the Linux kernel. We implement hXDP on an FPGA NIC and evaluate it running real-world unmodified eBPF programs. Our implementation is clocked at 156.25MHz, uses about 15% of the FPGA resources, and can run dynamically loaded programs. Despite these modest requirements, it achieves the packet processing throughput of a high-end CPU core and provides a 10x lower packet forwarding latency.