DPDK patches and discussions
 help / color / mirror / Atom feed
* [dpdk-dev] [PATCH] config: enable packet prefetching with Meson
@ 2020-11-13 14:52 Maxime Coquelin
  2020-11-13 15:05 ` Bruce Richardson
  0 siblings, 1 reply; 5+ messages in thread
From: Maxime Coquelin @ 2020-11-13 14:52 UTC (permalink / raw)
  To: dev, bruce.richardson, yong.liu, david.marchand; +Cc: Maxime Coquelin, stable

With Make build system, RTE_PMD_PACKET_PREFETCH was enabled
by default. It got lost when transitioning to Meson build
system.

In order to avoid performance changes, this patch enables
packet prefetching in rte_config.h.

Reported-by: Marvin Liu <yong.liu@intel.com>
Suggested-by: David Marchand <david.marchand@redhat.com>
Signed-off-by: Maxime Coquelin <maxime.coquelin@redhat.com>
---

Hi Bruce,

We were not sure whether adding below Fixes tag so that it is
backported to LTSes. What do you think?

Fixes: 9314afb68a53 ("drivers: add infrastructure for meson build")
Cc: stable@dpdk.org

 config/rte_config.h | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/config/rte_config.h b/config/rte_config.h
index 25219f04af..a0b5160ff2 100644
--- a/config/rte_config.h
+++ b/config/rte_config.h
@@ -103,6 +103,9 @@
 
 /****** driver defines ********/
 
+/* Packet prefetching in PMDs */
+#define RTE_PMD_PACKET_PREFETCH 1
+
 /* QuickAssist device */
 /* Max. number of QuickAssist devices which can be attached */
 #define RTE_PMD_QAT_MAX_PCI_DEVICES 48
-- 
2.26.2


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [dpdk-dev] [PATCH] config: enable packet prefetching with Meson
  2020-11-13 14:52 [dpdk-dev] [PATCH] config: enable packet prefetching with Meson Maxime Coquelin
@ 2020-11-13 15:05 ` Bruce Richardson
  2020-11-14  8:51   ` [dpdk-dev] [dpdk-stable] " Thomas Monjalon
  0 siblings, 1 reply; 5+ messages in thread
From: Bruce Richardson @ 2020-11-13 15:05 UTC (permalink / raw)
  To: Maxime Coquelin; +Cc: dev, yong.liu, david.marchand, stable

On Fri, Nov 13, 2020 at 03:52:12PM +0100, Maxime Coquelin wrote:
> With Make build system, RTE_PMD_PACKET_PREFETCH was enabled
> by default. It got lost when transitioning to Meson build
> system.
> 
> In order to avoid performance changes, this patch enables
> packet prefetching in rte_config.h.
> 
> Reported-by: Marvin Liu <yong.liu@intel.com>
> Suggested-by: David Marchand <david.marchand@redhat.com>
> Signed-off-by: Maxime Coquelin <maxime.coquelin@redhat.com>
> ---
> 
> Hi Bruce,
> 
> We were not sure whether adding below Fixes tag so that it is
> backported to LTSes. What do you think?
> 
> Fixes: 9314afb68a53 ("drivers: add infrastructure for meson build")
> Cc: stable@dpdk.org
> 
>  config/rte_config.h | 3 +++
>  1 file changed, 3 insertions(+)
> 
I view it as a gap in the transition from make to meson, so +1 for
adding these. Stable maintainers can then decide themselves on whether to
accept the patch or not.

/Bruce

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [dpdk-dev] [dpdk-stable] [PATCH] config: enable packet prefetching with Meson
  2020-11-13 15:05 ` Bruce Richardson
@ 2020-11-14  8:51   ` Thomas Monjalon
  2020-11-14  9:00     ` Thomas Monjalon
  0 siblings, 1 reply; 5+ messages in thread
From: Thomas Monjalon @ 2020-11-14  8:51 UTC (permalink / raw)
  To: Maxime Coquelin; +Cc: stable, dev, yong.liu, david.marchand, Bruce Richardson

13/11/2020 16:05, Bruce Richardson:
> On Fri, Nov 13, 2020 at 03:52:12PM +0100, Maxime Coquelin wrote:
> > With Make build system, RTE_PMD_PACKET_PREFETCH was enabled
> > by default. It got lost when transitioning to Meson build
> > system.
> > 
> > In order to avoid performance changes, this patch enables
> > packet prefetching in rte_config.h.
> > 
> > Reported-by: Marvin Liu <yong.liu@intel.com>
> > Suggested-by: David Marchand <david.marchand@redhat.com>
> > Signed-off-by: Maxime Coquelin <maxime.coquelin@redhat.com>
> > ---
> > 
> > Hi Bruce,
> > 
> > We were not sure whether adding below Fixes tag so that it is
> > backported to LTSes. What do you think?
> > 
> > Fixes: 9314afb68a53 ("drivers: add infrastructure for meson build")
> > Cc: stable@dpdk.org
> > 
> >  config/rte_config.h | 3 +++
> >  1 file changed, 3 insertions(+)
> > 
> I view it as a gap in the transition from make to meson, so +1 for
> adding these. Stable maintainers can then decide themselves on whether to
> accept the patch or not.

Applied with backport info, thanks.



^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [dpdk-dev] [dpdk-stable] [PATCH] config: enable packet prefetching with Meson
  2020-11-14  8:51   ` [dpdk-dev] [dpdk-stable] " Thomas Monjalon
@ 2020-11-14  9:00     ` Thomas Monjalon
  2020-11-14 10:54       ` David Marchand
  0 siblings, 1 reply; 5+ messages in thread
From: Thomas Monjalon @ 2020-11-14  9:00 UTC (permalink / raw)
  To: Maxime Coquelin; +Cc: dev, stable, yong.liu, david.marchand, Bruce Richardson

14/11/2020 09:51, Thomas Monjalon:
> 13/11/2020 16:05, Bruce Richardson:
> > On Fri, Nov 13, 2020 at 03:52:12PM +0100, Maxime Coquelin wrote:
> > > With Make build system, RTE_PMD_PACKET_PREFETCH was enabled
> > > by default. It got lost when transitioning to Meson build
> > > system.
> > > 
> > > In order to avoid performance changes, this patch enables
> > > packet prefetching in rte_config.h.
> > > 
> > > Reported-by: Marvin Liu <yong.liu@intel.com>
> > > Suggested-by: David Marchand <david.marchand@redhat.com>
> > > Signed-off-by: Maxime Coquelin <maxime.coquelin@redhat.com>
[...]
> 
> Applied with backport info, thanks.

Note that it is added back for "compatibility",
but I am still in favour of dropping this config option,
replaced by arch decision if any:
http://inbox.dpdk.org/dev/3677226.MZCibFMyqQ@thomas/

The decision of such optimization should be done in DPDK project,
not in the hand of the packager.



^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [dpdk-dev] [dpdk-stable] [PATCH] config: enable packet prefetching with Meson
  2020-11-14  9:00     ` Thomas Monjalon
@ 2020-11-14 10:54       ` David Marchand
  0 siblings, 0 replies; 5+ messages in thread
From: David Marchand @ 2020-11-14 10:54 UTC (permalink / raw)
  To: Thomas Monjalon, Yigit, Ferruh
  Cc: Maxime Coquelin, dev, dpdk stable, Marvin Liu, Bruce Richardson

On Sat, Nov 14, 2020 at 10:00 AM Thomas Monjalon <thomas@monjalon.net> wrote:
>
> 14/11/2020 09:51, Thomas Monjalon:
> > 13/11/2020 16:05, Bruce Richardson:
> > > On Fri, Nov 13, 2020 at 03:52:12PM +0100, Maxime Coquelin wrote:
> > > > With Make build system, RTE_PMD_PACKET_PREFETCH was enabled
> > > > by default. It got lost when transitioning to Meson build
> > > > system.
> > > >
> > > > In order to avoid performance changes, this patch enables
> > > > packet prefetching in rte_config.h.
> > > >
> > > > Reported-by: Marvin Liu <yong.liu@intel.com>
> > > > Suggested-by: David Marchand <david.marchand@redhat.com>
> > > > Signed-off-by: Maxime Coquelin <maxime.coquelin@redhat.com>
> [...]
> >
> > Applied with backport info, thanks.
>
> Note that it is added back for "compatibility",
> but I am still in favour of dropping this config option,
> replaced by arch decision if any:
> http://inbox.dpdk.org/dev/3677226.MZCibFMyqQ@thomas/
>
> The decision of such optimization should be done in DPDK project,
> not in the hand of the packager.

I am for dropping this too.
And for cleaning more prefetch-related stuff, like:

#if 1
#define RTE_PMD_USE_PREFETCH
#endif

#ifdef RTE_PMD_USE_PREFETCH
#define rte_em_prefetch(p)     rte_prefetch0(p)
#else
#define rte_em_prefetch(p)     do {} while(0)
#endif

This has been copied into other drivers.
The igc driver forgot(?) to force #define this macro, so it just
copied unused code.


-- 
David Marchand


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2020-11-14 10:54 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-11-13 14:52 [dpdk-dev] [PATCH] config: enable packet prefetching with Meson Maxime Coquelin
2020-11-13 15:05 ` Bruce Richardson
2020-11-14  8:51   ` [dpdk-dev] [dpdk-stable] " Thomas Monjalon
2020-11-14  9:00     ` Thomas Monjalon
2020-11-14 10:54       ` David Marchand

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