From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga11.intel.com (mga11.intel.com [192.55.52.93]) by dpdk.org (Postfix) with ESMTP id 7AD40C300 for ; Fri, 5 Feb 2016 16:07:49 +0100 (CET) Received: from orsmga001.jf.intel.com ([10.7.209.18]) by fmsmga102.fm.intel.com with ESMTP; 05 Feb 2016 07:07:48 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.22,401,1449561600"; d="scan'208";a="877813892" Received: from irsmsx104.ger.corp.intel.com ([163.33.3.159]) by orsmga001.jf.intel.com with ESMTP; 05 Feb 2016 07:07:48 -0800 Received: from irsmsx109.ger.corp.intel.com ([169.254.13.100]) by IRSMSX104.ger.corp.intel.com ([163.33.3.159]) with mapi id 14.03.0248.002; Fri, 5 Feb 2016 15:07:45 +0000 From: "Pattan, Reshma" To: Thomas Monjalon Thread-Topic: [dpdk-dev] [PATCH 1/3] examples/distributor: fix build for non-x86 arch Thread-Index: AQHRYCVX8DY703IFpECh6wqZbI1g5J8djOpA Date: Fri, 5 Feb 2016 15:07:44 +0000 Message-ID: <3AEA2BF9852C6F48A459DA490692831FFBEB4C@IRSMSX109.ger.corp.intel.com> References: <1454684049-27195-1-git-send-email-thomas.monjalon@6wind.com> <1454684049-27195-2-git-send-email-thomas.monjalon@6wind.com> In-Reply-To: <1454684049-27195-2-git-send-email-thomas.monjalon@6wind.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-titus-metadata-40: eyJDYXRlZ29yeUxhYmVscyI6IiIsIk1ldGFkYXRhIjp7Im5zIjoiaHR0cDpcL1wvd3d3LnRpdHVzLmNvbVwvbnNcL0ludGVsMyIsImlkIjoiZjAyYjE5YTktYmU0Ny00YTkyLTkxNWItOTU1MDI1MWE3MTVlIiwicHJvcHMiOlt7Im4iOiJDVFBDbGFzc2lmaWNhdGlvbiIsInZhbHMiOlt7InZhbHVlIjoiQ1RQX0lDIn1dfV19LCJTdWJqZWN0TGFiZWxzIjpbXSwiVE1DVmVyc2lvbiI6IjE1LjQuMTAuMTkiLCJUcnVzdGVkTGFiZWxIYXNoIjoiV2hmblJWMUxmN2w5Y3JGWGpyZlVyVFZXXC9POFBDQWFRM09hbTJKNzVzSVU9In0= x-ctpclassification: CTP_IC x-originating-ip: [163.33.239.180] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Cc: "dev@dpdk.org" Subject: Re: [dpdk-dev] [PATCH 1/3] examples/distributor: fix build for non-x86 arch 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: Fri, 05 Feb 2016 15:07:49 -0000 Hi Thomas, > -----Original Message----- > From: dev [mailto:dev-bounces@dpdk.org] On Behalf Of Thomas Monjalon > Sent: Friday, February 5, 2016 2:54 PM > To: Richardson, Bruce; Horton, Remy > Cc: dev@dpdk.org > Subject: [dpdk-dev] [PATCH 1/3] examples/distributor: fix build for non-x= 86 arch >=20 > _mm_prefetch is defined only in x86 compilers. > rte_prefetch functions are defined in EAL for each arch, and must be pref= erred > over compiler intrinsics. >=20 > Fixes: 07db4a975094 ("examples/distributor: new sample app") >=20 > Signed-off-by: Thomas Monjalon > --- > examples/distributor/main.c | 8 ++++---- > 1 file changed, 4 insertions(+), 4 deletions(-) >=20 > diff --git a/examples/distributor/main.c b/examples/distributor/main.c in= dex > 4e74f8f..87344ac 100644 > --- a/examples/distributor/main.c > +++ b/examples/distributor/main.c > @@ -335,13 +335,13 @@ lcore_tx(struct rte_ring *in_r) >=20 > /* for traffic we receive, queue it up for transmit */ > uint16_t i; > - _mm_prefetch((void *)bufs[0], 0); > - _mm_prefetch((void *)bufs[1], 0); > - _mm_prefetch((void *)bufs[2], 0); > + rte_prefetch0((void *)bufs[0]); > + rte_prefetch0((void *)bufs[1]); > + rte_prefetch0((void *)bufs[2]); Some time back Jerin Jacob has sent patch for replacing the _mm_prefetch w= ith rte_prefetch_non_temporal. This is FYI. Thanks, Reshma > for (i =3D 0; i < nb_rx; i++) { > struct output_buffer *outbuf; > uint8_t outp; > - _mm_prefetch((void *)bufs[i + 3], 0); > + rte_prefetch0((void *)bufs[i + 3]); > /* > * workers should update in_port to hold the > * output port value > -- > 2.7.0