From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from tyo201.gate.nec.co.jp (TYO201.gate.nec.co.jp [210.143.35.51]) by dpdk.org (Postfix) with ESMTP id 4841B5922 for ; Thu, 25 Sep 2014 03:06:07 +0200 (CEST) Received: from mailgate3.nec.co.jp ([10.7.69.193]) by tyo201.gate.nec.co.jp (8.13.8/8.13.4) with ESMTP id s8P1CG7a020006; Thu, 25 Sep 2014 10:12:16 +0900 (JST) Received: from mailsv4.nec.co.jp (imss63.nec.co.jp [10.7.69.158]) by mailgate3.nec.co.jp (8.11.7/3.7W-MAILGATE-NEC) with ESMTP id s8P1CGC27051; Thu, 25 Sep 2014 10:12:16 +0900 (JST) Received: from mail01b.kamome.nec.co.jp (mail01b.kamome.nec.co.jp [10.25.43.2]) by mailsv4.nec.co.jp (8.13.8/8.13.4) with ESMTP id s8P1CGom014310; Thu, 25 Sep 2014 10:12:16 +0900 (JST) Received: from bpxc99gp.gisp.nec.co.jp ([10.38.151.143] [10.38.151.143]) by mail02.kamome.nec.co.jp with ESMTP id BT-MMP-2098331; Thu, 25 Sep 2014 10:12:03 +0900 Received: from BPXM14GP.gisp.nec.co.jp ([169.254.1.136]) by BPXC15GP.gisp.nec.co.jp ([10.38.151.143]) with mapi id 14.03.0174.002; Thu, 25 Sep 2014 10:12:02 +0900 From: Hiroshi Shimamoto To: "Wiles, Roger Keith" , Thomas Monjalon Thread-Topic: [dpdk-dev] [memnic PATCH 7/7] pmd: split calling mbuf free Thread-Index: AQHP2AsdRuD9Hiu0m0qneK79F6ykrZwP2oEAgAEsgEA= Date: Thu, 25 Sep 2014 01:12:01 +0000 Message-ID: <7F861DC0615E0C47A872E6F3C5FCDDBD02ADA02E@BPXM14GP.gisp.nec.co.jp> References: <7F861DC0615E0C47A872E6F3C5FCDDBD011A99C6@BPXM14GP.gisp.nec.co.jp> <16805029.uPnEfVsb0t@xps13> In-Reply-To: Accept-Language: ja-JP, en-US Content-Language: ja-JP X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.205.5.123] Content-Type: text/plain; charset="iso-2022-jp" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Cc: "dev@dpdk.org" , Hayato Momma Subject: Re: [dpdk-dev] [memnic PATCH 7/7] pmd: split calling mbuf free X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 25 Sep 2014 01:06:07 -0000 Hi Thomas, Keith, > Subject: Re: [dpdk-dev] [memnic PATCH 7/7] pmd: split calling mbuf free >=20 >=20 > On Sep 24, 2014, at 10:20 AM, Thomas Monjalon = wrote: >=20 > > 2014-09-11 07:52, Hiroshi Shimamoto: > >> @@ -408,9 +408,9 @@ retry: > >> > >> rte_compiler_barrier(); > >> p->status =3D MEMNIC_PKT_ST_FILLED; > >> - > >> - rte_pktmbuf_free(tx_pkts[nr]); > >> } > >> + for (i =3D 0; i < nr; i++) > >> + rte_pktmbuf_free(tx_pkts[i]); > >> > >> /* stats */ > >> st->opackets +=3D pkts; > >> > > > > You are bursting mbuf freeing. Why title is about "split=1B$B!I=1B(B? I thought that in this patch splits main loop operations to putting content= and freeing mbuf, then took work "split", but I see "burst mbuf freeing" is pre= ferable. >=20 > Maybe this should be a new API as in rte_pktmbuf_bulk_free(tx_pkts, nr); = ?? > This would remove the loop in the application and I know I have done the = same thing for Pktgen too. Good point, yes, I'm thinking that having new API like rte_pktmbuf_(alloc|f= ree)_bulk() is good to reduce TLS access and gain performance. I put that on my stack, but haven't had a time yet. Do you have any plan to do such thing? thanks, Hiroshi > > > > -- > > Thomas >=20 > Keith Wiles, Principal Technologist with CTO office, Wind River mobile 97= 2-213-5533