From mboxrd@z Thu Jan 1 00:00:00 1970 From: Thomas Monjalon Subject: Re: [PATCH] kni: optimizing the rte_kni_rx_burst Date: Tue, 24 Feb 2015 02:29:14 +0100 Message-ID: <7915859.T53PE4ELEn@xps13> References: <14060979121185-git-send-email-Hemant@freescale.com> <1520998.LI3zsdbzN8@xps13> <2263080.JfiolkiDdp@xps13> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7Bit Cc: dev-VfR2kkLFssw@public.gmane.org To: Hemant Agrawal Return-path: In-Reply-To: <2263080.JfiolkiDdp@xps13> List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces-VfR2kkLFssw@public.gmane.org Sender: "dev" > > > 2014-07-23 12:15, Hemant Agrawal: > > > > The current implementation of rte_kni_rx_burst polls the fifo for buffers. > > > > Irrespective of success or failure, it allocates the mbuf and try to put them into the alloc_q > > > > if the buffers are not added to alloc_q, it frees them. > > > > This waste lots of cpu cycles in allocating and freeing the buffers if alloc_q is full. > > > > > > > > The logic has been changed to: > > > > 1. Initially allocand add buffer(burstsize) to alloc_q > > > > 2. Add buffers to alloc_q only when you are pulling out the buffers. > > > > > > > > Signed-off-by: Hemant Agrawal > > From http://dpdk.org/ml/archives/dev/2015-January/011771.html, Jay said > "The patch looks good from a DPDK 1.6r2 viewpoint. We saw the same behavior > in our app and ended up avoiding it higher in the stack (in our code)." > Reviewed-by: Jay Rolette Applied, thanks