摘要
近年来,LwIP协议栈已经在嵌入式系统上得到了广泛的应用,但由于嵌入式处理器性能及实时操作系统效率的影响,应用于嵌入式上的LwIP协议栈的实测性能和理论值之间一直存在较大差距。分析了UDP协议的结构,并在富士通H60高清机顶盒(ARM11体系架构、100M以太网控制器)平台下,通过调用精确到1us的系统时钟,测量了UDP协议接收1KB报文的每个环节所用时间,发现制约UDP协议性能的主要瓶颈之一是内存拷贝,最后,针对内存拷贝给出了一个优化算法。经测试,整体效率提高了32%。
In recent years,LwIP protocol stack has been widely used in embedded systems.However,because of the impacts of embedded processor performance and RTOS efficiency,the measured performance of LwIP protocol stack applied in embedded system is actually far below the theoretical value.In this paper we analyse the structure of UDP protocol,and measure on Fujitsu H60 HD Set Top Box(ARM11 architecture and 100M Ethernet controller) platform the time cost of every link when receiving 1 KB message by UDP protocol through revoking a system timer with 1us accuracy.It is found that one of the most time-consuming parts turned out to be the memory copy,so an optimised algorithm for memory copy is finally given.According to the final test,the overall system efficiency increased 32%.
出处
《计算机应用与软件》
CSCD
2011年第3期246-249,共4页
Computer Applications and Software