在分析现有零拷贝通信协议实现的基础上,提出了基于实时微内核的零拷贝通信协议RTZCP.针对不同的应用场景,RTZCP协议对单个数据包采用了传统的内存重映射方式来消除用户空间与内核空间之间的数据拷贝,而对于需要分片的大数据包,则采用RMA(远程内存访问)方式来实现零拷贝通信的目的,设立了专门静态网络通信资源的分配管理机制,以及具有缓冲机制的通信接口技术来优化处理IP数据包的分片机制,测试结果表明,RTZCP协议能够在提供比传统网络通信协议更低的通信延时的情况下,充分地保证实时数据包的实时通信性能.
After the implementation of current zero-copy communication protocols is analyzed, a new zero-copy communication protocol based on the real-time micro-kernel, real-time zero-copy communication protocol(RTZCP) is proposed. RTZCP adopts traditional memory mapping mechanism to eliminate the data copies between the user space and the kernel space for single packets, while using the RMA (Remote Memory Access) technique to realize Zero-Copy communication data paths for IP fragments. On the other hand, special static network communication resources allocating and managing mechanism, as well as the communication interface technique with buffering supports, are provided to optimize the fragmentation mechanism of IP fragments. The experiment results show that RTZCP not only can provide lower communication latency than traditional Linux network communication protocol, but also satisfy real-time performance for real-time communications.