DPDK patches and discussions
 help / color / mirror / Atom feed
From: Bruce Richardson <bruce.richardson@intel.com>
To: "Loftus, Ciara" <ciara.loftus@intel.com>
Cc: "dev@dpdk.org" <dev@dpdk.org>
Subject: Re: [PATCH v2 12/15] net/intel: introduce infrastructure for Rx path selection
Date: Mon, 18 Aug 2025 12:23:51 +0100	[thread overview]
Message-ID: <aKMNR0MgCNBtWYYR@bricha3-mobl1.ger.corp.intel.com> (raw)
In-Reply-To: <SJ5PPF6E320AF71904ABC4769CFD6CE4CF18E31A@SJ5PPF6E320AF71.namprd11.prod.outlook.com>

On Mon, Aug 18, 2025 at 11:58:22AM +0100, Loftus, Ciara wrote:
> > >
> > > They're not necessarily needed but I think they improve the readability when
> > they are used in the next three patches when defining the features of each Rx
> > burst function. If you don't agree I can remove them.
> > >
> > 
> > I'd tend to prefer assigning bools to just true/false for type-safety and
> > type-clarity. In terms of readability with defines like above: if we do
> > want separate defines for scattered, flex-desc etc. I'd tend toward having
> > them as enums and the variables below typed using those enums.
> > Unfortunately, that's not really feasible with the struct below, because
> > while bools only occupy 1 byte, even a two-element enum would use up 4
> > bytes per value, which is padding we cannot afford. :-(
> > 
> > 
> 
> I went with splitting out the boolean features into their own sub-structure, which you suggested in a previous thread.
> 
> The definition can look like this now:
> 
> [I40E_RX_AVX512_SCATTERED] = { i40e_recv_scattered_pkts_vec_avx512,
> 	"Vector AVX512 Scattered", {I40E_RX_VECTOR_OFFLOADS, RTE_VECT_SIMD_512,
> 		{.scattered = true, .bulk_alloc = true}}},
> 
> Let me know what you think. It's perhaps a bit unusual with the nested structures but I'm ok with that since it's more readable than a series of true/false. However, if you would like to just go with the simple true/false approach I'm happy to spin up a new patch.
> 
> Ciara
> 
I'll review in the v3, but that does indeed look quite readable to me.

/Bruce

  reply	other threads:[~2025-08-18 11:24 UTC|newest]

Thread overview: 54+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-07-25 12:49 [RFC PATCH 00/14] net/intel: rx path selection simplification Ciara Loftus
2025-07-25 12:49 ` [RFC PATCH 01/14] net/ice: use the same Rx path across process types Ciara Loftus
2025-07-25 13:40   ` Bruce Richardson
2025-07-25 12:49 ` [RFC PATCH 02/14] net/iavf: rename Rx/Tx function type variables Ciara Loftus
2025-07-25 13:40   ` Bruce Richardson
2025-07-25 12:49 ` [RFC PATCH 03/14] net/iavf: use the same Rx path across process types Ciara Loftus
2025-07-25 13:41   ` Bruce Richardson
2025-07-25 12:49 ` [RFC PATCH 04/14] net/i40e: " Ciara Loftus
2025-07-25 13:43   ` Bruce Richardson
2025-07-25 12:49 ` [RFC PATCH 05/14] net/intel: introduce common vector capability function Ciara Loftus
2025-07-25 13:45   ` Bruce Richardson
2025-07-25 12:49 ` [RFC PATCH 06/14] net/ice: use the new " Ciara Loftus
2025-07-25 13:56   ` Bruce Richardson
2025-08-06 14:46     ` Loftus, Ciara
2025-07-25 12:49 ` [RFC PATCH 07/14] net/iavf: " Ciara Loftus
2025-07-25 12:49 ` [RFC PATCH 08/14] net/i40e: " Ciara Loftus
2025-07-25 12:49 ` [RFC PATCH 09/14] net/iavf: remove redundant field from iavf adapter struct Ciara Loftus
2025-07-25 14:51   ` Bruce Richardson
2025-07-25 12:49 ` [RFC PATCH 10/14] net/intel: introduce infrastructure for Rx path selection Ciara Loftus
2025-07-25 15:21   ` Bruce Richardson
2025-08-06 10:14     ` Loftus, Ciara
2025-08-06 10:36       ` Bruce Richardson
2025-07-25 12:49 ` [RFC PATCH 11/14] net/ice: remove unsupported Rx offload Ciara Loftus
2025-07-25 15:22   ` Bruce Richardson
2025-07-25 12:49 ` [RFC PATCH 12/14] net/ice: use the common Rx path selection infrastructure Ciara Loftus
2025-07-25 12:49 ` [RFC PATCH 13/14] net/iavf: " Ciara Loftus
2025-07-25 12:49 ` [RFC PATCH 14/14] net/i40e: " Ciara Loftus
2025-08-07 12:39 ` [PATCH v2 00/15] net/intel: rx path selection simplification Ciara Loftus
2025-08-07 12:39   ` [PATCH v2 01/15] net/ice: use the same Rx path across process types Ciara Loftus
2025-08-07 12:39   ` [PATCH v2 02/15] net/iavf: rename Rx/Tx function type variables Ciara Loftus
2025-08-07 12:39   ` [PATCH v2 03/15] net/iavf: use the same Rx path across process types Ciara Loftus
2025-08-07 12:39   ` [PATCH v2 04/15] net/i40e: " Ciara Loftus
2025-08-07 12:39   ` [PATCH v2 05/15] net/intel: introduce common vector capability function Ciara Loftus
2025-08-07 12:39   ` [PATCH v2 06/15] net/ice: use the new " Ciara Loftus
2025-08-11 10:47     ` Bruce Richardson
2025-08-14 13:16       ` Loftus, Ciara
2025-08-07 12:39   ` [PATCH v2 07/15] net/iavf: " Ciara Loftus
2025-08-11 10:48     ` Bruce Richardson
2025-08-07 12:39   ` [PATCH v2 08/15] net/i40e: " Ciara Loftus
2025-08-11 10:53     ` Bruce Richardson
2025-08-07 12:39   ` [PATCH v2 09/15] net/iavf: remove redundant field from iavf adapter struct Ciara Loftus
2025-08-07 12:39   ` [PATCH v2 10/15] net/ice: remove unsupported Rx offload Ciara Loftus
2025-08-07 12:39   ` [PATCH v2 11/15] net/iavf: reorder enum of Rx function types Ciara Loftus
2025-08-11 10:56     ` Bruce Richardson
2025-08-07 12:39   ` [PATCH v2 12/15] net/intel: introduce infrastructure for Rx path selection Ciara Loftus
2025-08-11 11:36     ` Bruce Richardson
2025-08-14 13:35       ` Loftus, Ciara
2025-08-18  8:18         ` Bruce Richardson
2025-08-18 10:58           ` Loftus, Ciara
2025-08-18 11:23             ` Bruce Richardson [this message]
2025-08-07 12:39   ` [PATCH v2 13/15] net/ice: use the common Rx path selection infrastructure Ciara Loftus
2025-08-11 17:03     ` Bruce Richardson
2025-08-07 12:39   ` [PATCH v2 14/15] net/iavf: " Ciara Loftus
2025-08-07 12:39   ` [PATCH v2 15/15] net/i40e: " Ciara Loftus

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=aKMNR0MgCNBtWYYR@bricha3-mobl1.ger.corp.intel.com \
    --to=bruce.richardson@intel.com \
    --cc=ciara.loftus@intel.com \
    --cc=dev@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
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).