The network stack f-Stack 1.24 has been published, which is an implementation of the network stack FreeBSD functioning in the user’s space and utilizing the framework dpdk for achieving maximum performance. This project, created by the largest telecommunication company in China Tencent, is utilized in its products and services. The code, written in the si language, is distributed under the BSD license and is supported in Linux and FreeBSD.
F-Stack enables the use of its own local network stack within applications, independent of the operating system’s network stack, operating in the user space and directly interfacing with network equipment. Positioned as a solution to enhance the performance of network request processors, F-Stack overcomes limitations in scaling when the standard TCP/IP stack of the Linux kernel restricts performance. In certain scenarios, this project enables an increase in the number of processed small network queries, potentially achieving the maximum network performance achievable with the network card in use.
The performance enhancement is achieved by eliminating operations such as network package copying, flow scheduling, interrupt processing, and system call usage. To interact with the network card while bypassing the operating system kernel interfaces, the framework employs DPDK (Data Plane Development Kit), which provides libraries for low-level adapters. DPDK minimizes overhead costs and reduces the required CPU cycles for processing network packages.
The TCP/IP stack functionality aligns with the FreeBSD 13 network stack and has been extracted from this operating system to form an independent library. When developing applications, standard APIs such as Posix (SOCKET, EPOLL, kqueue) can be utilized, or developers can create their own software interface based on microservices, streamlining network application development and simplifying complex asynchronous query processing logic.
The latest release also supports the nginx 1.25.2 multi-process server and DBMS Redis 6.2.6, showcasing superior performance compared to standard configurations operating on top of the system network stack.
The major changes in the new release include: