Statistical counting method of network processor
暂无分享,去创建一个
The invention provides a statistical counting method of a network processor. The statistical counting method is characterized in that when the network processor starts a conversation, a statistical counter is distributed for the conversation, and statistical items send statistical requests in a statistical order mode in the conversation; all statistical orders are polled and arbitrated, the statistical items are counted, and a statistical counter is updated; after the conversation is finished, the address of the statistical counter is recycled; the statistical counter is polled in idle time of statistical counting, and corresponding statistical messages are generated according to a threshold value of the statistical counter. Complicated statistical messages in the network processor are packed into the statistical orders, the statistical module carries out statistical counting in a statistical order mode, processing procedures of statistical counting are simplified and hardware implementation is easy.