hXDP:在FPGA上高效的软件包处理
hXDP: Efficient Software Packet Processing on FPGA NICs
摘要:
NIC上的FPGA加速器可以将昂贵的数据包处理任务从CPU上卸载。然而,FPGA的资源有限,可能需要在不同的应用程序之间共享,并且很难对其进行编程。我们提出了一种解决方案,在FPGA上运行Linux的eXpress数据路径程序,使用只有一小部分的可用硬件资源,同时匹配高端CPU的性能。eBPF的迭代执行模型不适合FPGA加速器。尽管如此,我们表明,eBPF程序的许多指令可以被压缩,并行化或完全删除,当目标是一个专用的FPGA执行器,从而显着提高性能。我们利用这一点来设计hXDP,它包括(i)一个优化编译器,它将eBPF字节码并行化并转换为我们定义的扩展eBPF指令集架构;(ii)一个软CPU,用于在FPGA上执行这些指令;以及(iii)一个基于FPGA的基础设施,用于提供Linux内核中定义的XDP映射和帮助函数。我们在FPGA NIC上实现了hXDP,并运行真实世界中未修改的eBPF程序对其进行了评估。我们的实现是在156.25MHz的时钟,使用约15%的FPGA资源,并可以运行动态加载的程序。尽管有这些适度的要求,但它实现了高端CPU核心的数据包处理吞吐量,并提供了10倍的数据包转发延迟。
英文摘要:
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.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。