DPDK patches and discussions
 help / color / mirror / Atom feed
From: "Kulasek, TomaszX" <tomaszx.kulasek@intel.com>
To: Jan Viktorin <viktorin@rehivetech.com>,
	Thomas Monjalon <thomas.monjalon@6wind.com>
Cc: Jerin Jacob <jerin.jacob@caviumnetworks.com>,
	"dev@dpdk.org" <dev@dpdk.org>,
	"jianbo.liu@linaro.org" <jianbo.liu@linaro.org>
Subject: Re: [dpdk-dev] [PATCH v5] examples/l3fwd: em path performance fix
Date: Fri, 18 Mar 2016 12:45:03 +0000	[thread overview]
Message-ID: <3042915272161B4EB253DA4D77EB373A14E6C71E@IRSMSX102.ger.corp.intel.com> (raw)
In-Reply-To: <20160318125650.7469a086@pcviktorin.fit.vutbr.cz>



> -----Original Message-----
> From: Jan Viktorin [mailto:viktorin@rehivetech.com]
> Sent: Friday, March 18, 2016 12:57
> To: Thomas Monjalon <thomas.monjalon@6wind.com>
> Cc: Jerin Jacob <jerin.jacob@caviumnetworks.com>; Kulasek, TomaszX
> <tomaszx.kulasek@intel.com>; dev@dpdk.org; jianbo.liu@linaro.org
> Subject: Re: [dpdk-dev] [PATCH v5] examples/l3fwd: em path performance fix
> 
> Hello Thomas, Jerin, Tomasz, all...
> 
> On Fri, 18 Mar 2016 12:00:24 +0100
> Thomas Monjalon <thomas.monjalon@6wind.com> wrote:
> 
> > 2016-03-18 16:22, Jerin Jacob:
> > > On Fri, Mar 18, 2016 at 11:04:49AM +0100, Thomas Monjalon wrote:
> > > > 2016-03-18 10:52, Tomasz Kulasek:
> > > > > +#if !defined(NO_HASH_MULTI_LOOKUP) && defined(__ARM_NEON)
> > > >
> > > > I think we should use CONFIG_RTE_ARCH_ARM_NEON here.
> > > > Any ARM maintainer to confirm?
> > >
> > > __ARM_NEON should work existing GCC, but it is better to use
> > > RTE_MACHINE_CPUFLAG_NEON as -it has been generated by probing the
> > > compiler capabilities.
> > > -it's future-proof solution to support clang or other gcc versions
> > > in future
> >
> > I agree to use RTE_MACHINE_CPUFLAG_NEON.
> >
> > I just don't understand why CONFIG_RTE_ARCH_ARM_NEON has been
> introduced.
> > It seems to be used to disable NEON on ARMv7:
> 
> This is true. You should be able to disable the NEON-specific code if it
> is unwanted. Eg., the memcpy operations are not always faster with NEON.
> But...
> 
> $ git grep ARM_NEON
> ...
> lib/librte_eal/common/include/arch/arm/rte_memcpy_32.h:45:#ifdef
> __ARM_NEON_FP
> lib/librte_eal/common/include/arch/arm/rte_memcpy_32.h:328:#endif /*
> __ARM_NEON_FP */ ...
> 
> From this point of view, this is wrong and should be fixed to check a
> different constant.
> 
> > 	ifeq ($(CONFIG_RTE_ARCH_ARM_NEON),y)
> > 	MACHINE_CFLAGS += -mfpu=neon
> > 	endif
> 
> However, there is another possible way of understanding these options.
> We can (well, unlikely and I am about to say 'never') have an ARM
> processor without NEON. This cannot be detected by gcc as it does not know
> the target processor... So from my point of view:
> 
> * CONFIG_RTE_ARCH_ARM_NEON says "my CPU does (not) support NEON" or "I
>   want to enable/disable NEON" while
> * RTE_MACHINE_CPUFLAG_NEON says, the _compiler_ supports NEON
> 
> I'll send a patch trying to solve this.
> 
> Regards
> Jan

Hi

As I understand with your last patch it's safe and preferred to use RTE_MACHINE_CPUFLAG_NEON for ARM Neon detection? If so, I can include this modification for whole l3fwd in v6 of this patch.

Tomasz.

  reply	other threads:[~2016-03-18 12:45 UTC|newest]

Thread overview: 25+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-03-03 17:23 [dpdk-dev] [PATCH] " Tomasz Kulasek
2016-03-07  6:19 ` Xu, Qian Q
2016-03-08 12:58 ` [dpdk-dev] [PATCH v2] " Tomasz Kulasek
2016-03-11 11:14   ` Thomas Monjalon
2016-03-11 12:28     ` Kulasek, TomaszX
2016-03-11 12:10   ` [dpdk-dev] [PATCH v3] " Tomasz Kulasek
2016-03-11 16:23     ` Thomas Monjalon
2016-03-11 17:48       ` Kulasek, TomaszX
2016-03-15 14:31         ` Kulasek, TomaszX
2016-03-15 14:49           ` Thomas Monjalon
2016-03-15 16:06             ` Kulasek, TomaszX
2016-03-15 19:42               ` [dpdk-dev] Odp.: " Czekaj, Maciej
2016-03-18  9:36     ` [dpdk-dev] [PATCH v4] " Tomasz Kulasek
2016-03-18  9:43       ` Kulasek, TomaszX
2016-03-18  9:52       ` [dpdk-dev] [PATCH v5] " Tomasz Kulasek
2016-03-18 10:04         ` Thomas Monjalon
2016-03-18 10:52           ` Jerin Jacob
2016-03-18 11:00             ` Thomas Monjalon
2016-03-18 11:16               ` [dpdk-dev] [PATCH] examples/l3fwd: prefer probed NEON flag to ARM gcc flag Thomas Monjalon
2016-03-18 11:20                 ` [dpdk-dev] [PATCH v2] " Thomas Monjalon
2016-03-18 11:56               ` [dpdk-dev] [PATCH v5] examples/l3fwd: em path performance fix Jan Viktorin
2016-03-18 12:45                 ` Kulasek, TomaszX [this message]
2016-03-18 12:50                   ` Jan Viktorin
2016-03-18 13:31         ` [dpdk-dev] [PATCH v6] " Tomasz Kulasek
2016-03-21 11:57           ` Thomas Monjalon

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=3042915272161B4EB253DA4D77EB373A14E6C71E@IRSMSX102.ger.corp.intel.com \
    --to=tomaszx.kulasek@intel.com \
    --cc=dev@dpdk.org \
    --cc=jerin.jacob@caviumnetworks.com \
    --cc=jianbo.liu@linaro.org \
    --cc=thomas.monjalon@6wind.com \
    --cc=viktorin@rehivetech.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).