DPDK patches and discussions
 help / color / mirror / Atom feed
From: Thomas Monjalon <thomas@monjalon.net>
To: Bruce Richardson <bruce.richardson@intel.com>
Cc: dev@dpdk.org, techboard@dpdk.org, Ferruh Yigit <ferruh.yigit@intel.com>
Subject: Re: [dpdk-dev] [dpdk-techboard] [PATCH 1/1] doc: add deprecation notice for CPU build flags
Date: Fri, 07 Aug 2020 15:48:43 +0200
Message-ID: <2289852.h2yjUt0C1Z@thomas> (raw)
In-Reply-To: <27d08eb2-5f66-e385-3d05-39ac317ece89@intel.com>

06/08/2020 23:41, Ferruh Yigit:
> On 8/5/2020 5:45 PM, Bruce Richardson wrote:
> > On Wed, Aug 05, 2020 at 05:15:31PM +0200, Thomas Monjalon wrote:
> >> 05/08/2020 17:07, Bruce Richardson:
> >>> On Wed, Aug 05, 2020 at 04:57:42PM +0200, Thomas Monjalon wrote:
> >>>> 05/08/2020 16:21, Bruce Richardson:
> >>>>> The RTE_MACHINE_CPUFLAGS_* macros in DPDK build just duplicate info from
> >>>>> the compiler macros, so we can remove them and just use the compiler
> >>>>> versions directly.
> >>>>>
> >>>>> Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
> >>>>> ---
> >>>>> --- a/doc/guides/rel_notes/deprecation.rst
> >>>>> +++ b/doc/guides/rel_notes/deprecation.rst
> >>>>> +* build macros: The macros defining RTE_MACHINE_CPUFLAG_* will be removed
> >>>>> +  from the build. The information provided by these macros is available
> >>>>> +  through standard compiler macros. For example, RTE_MACHINE_CPUFLAG_SSE3
> >>>>> +  duplicates the compiler-provided macro __SSE3__.
> >>>>
> >>>> I see 2 advantages of having alias:
> >>>> 	- if 2 compilers differ, we can manage
> >>>> 	- we can find all such macros with grep RTE_MACHINE_CPUFLAG
> >>>>
> >>>
> >>> Sure, if you think it's worthwhile keeping them, we can do so. It's just
> >>> right now they seem to be largely a waste of space. For #2, I'm not sure
> >>> when we would want to grep for them all, except possibly to remove them.
> >>> :-)
> >>
> >> For instance, in a lib, I grep where we have CPU specific code.
> >>
> >> We probably need more opinions, I can change my mind.
> >>
> > Yes, we need some more opinions here.
> > 
> > For the above point, yes it's useful to be able to grep for these things,
> > but it does assume that everybody uses the DPDK-defines and doesn't use the
> > compiler ones directly. There are a few instances where there seems to be
> > x86, ARM or PPC compiler flags already directly used in the code.
> > 
> > As well as brevity, the other big reason I see for removing them is to
> > avoid having to maintain these lists of flags for future use. Right now,
> > with -march=skylake-avx512, gcc will define 7 different AVX feature flags.
> > DPDK, on the other hand, only provides equivalent defines for 3 of them.
> > We have no automatic way of pulling all newly added flags from gcc/clang
> > into our build, so we just add them on an as-needed basis, which makes it
> > more awkward for those adding new features that may depend on the flags. If
> > we always try to add in all flags to keep things in sync, we are just
> > duplicating the efforts the compiler authors have already done for us, and
> > wasting the effort for those flags that are unused.
> > 
> 
> Sounds reasonable,
> 
> Acked-by: Ferruh Yigit <ferruh.yigit@intel.com>

Applied




      reply	other threads:[~2020-08-07 13:48 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-08-05 14:21 [dpdk-dev] [PATCH 0/1] RFC: remove build-type CPU flag macros Bruce Richardson
2020-08-05 14:21 ` [dpdk-dev] [PATCH 1/1] doc: add deprecation notice for CPU build flags Bruce Richardson
2020-08-05 14:23   ` Jerin Jacob
2020-08-05 14:57   ` [dpdk-dev] [dpdk-techboard] " Thomas Monjalon
2020-08-05 15:07     ` Bruce Richardson
2020-08-05 15:15       ` Thomas Monjalon
2020-08-05 16:45         ` Bruce Richardson
2020-08-05 17:02           ` Thomas Monjalon
2020-08-06 16:01             ` Thomas Monjalon
2020-08-06 21:41           ` Ferruh Yigit
2020-08-07 13:48             ` Thomas Monjalon [this message]

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=2289852.h2yjUt0C1Z@thomas \
    --to=thomas@monjalon.net \
    --cc=bruce.richardson@intel.com \
    --cc=dev@dpdk.org \
    --cc=ferruh.yigit@intel.com \
    --cc=techboard@dpdk.org \
    /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

DPDK patches and discussions

This inbox may be cloned and mirrored by anyone:

	git clone --mirror https://inbox.dpdk.org/dev/0 dev/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 dev dev/ https://inbox.dpdk.org/dev \
		dev@dpdk.org
	public-inbox-index dev

Example config snippet for mirrors.
Newsgroup available over NNTP:
	nntp://inbox.dpdk.org/inbox.dpdk.dev


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git