From: Bruce Richardson <bruce.richardson@intel.com>
To: "Loftus, Ciara" <ciara.loftus@intel.com>
Cc: "dev@dpdk.org" <dev@dpdk.org>
Subject: Re: [PATCH 1/1] net/i40e: unset vector flag when scalar path is chosen
Date: Wed, 17 Dec 2025 15:33:13 +0000 [thread overview]
Message-ID: <aULNOcN6-wCBIFNY@bricha3-mobl1.ger.corp.intel.com> (raw)
In-Reply-To: <DM3PPF7D18F34A12F8DA79F7B83D9E2C3E18EABA@DM3PPF7D18F34A1.namprd11.prod.outlook.com>
On Wed, Dec 17, 2025 at 03:18:42PM +0000, Loftus, Ciara wrote:
> > Subject: Re: [PATCH 1/1] net/i40e: unset vector flag when scalar path is
> > chosen
> >
> > On Wed, Dec 17, 2025 at 02:54:36PM +0000, Ciara Loftus wrote:
> > > The tx_vec_allowed flag should be set to false if a scalar Tx path is
> > > chosen.
> > >
> > > Fixes: 1ff08bb7ad90 ("net/i40e: use common Tx path selection
> > infrastructure")
> > >
> > > Signed-off-by: Ciara Loftus <ciara.loftus@intel.com>
> > > ---
> > > drivers/net/intel/i40e/i40e_rxtx.c | 3 +++
> > > 1 file changed, 3 insertions(+)
> > >
> > > diff --git a/drivers/net/intel/i40e/i40e_rxtx.c
> > b/drivers/net/intel/i40e/i40e_rxtx.c
> > > index 2db58c6b24..dd859bda4e 100644
> > > --- a/drivers/net/intel/i40e/i40e_rxtx.c
> > > +++ b/drivers/net/intel/i40e/i40e_rxtx.c
> > > @@ -3631,6 +3631,9 @@ i40e_set_tx_function(struct rte_eth_dev *dev)
> > > ad->tx_func_type == I40E_TX_ALTIVEC ||
> > > ad->tx_func_type == I40E_TX_AVX2)
> > > dev->recycle_tx_mbufs_reuse =
> > i40e_recycle_tx_mbufs_reuse_vec;
> > > +
> > > + if (i40e_tx_path_infos[ad->tx_func_type].features.simd_width <
> > RTE_VECT_SIMD_128)
> > > + ad->tx_vec_allowed = false;
> > > }
> > >
> > Under what circumstances would this be a problem, or under what
> > circumstances would we have this situaion?
>
> The circumstances we would have this situation is when the driver
> determines that tx vectorisation is allowed but we end up selecting
> a scalar path. The result would be "vector_tx" being set for the txq
> during tx_queue_start and later during tx_queue_stop, the wrong
> path being taken in ci_txq_release_all_mbufs
>
Would this be better fixed by some refactoring to chose the release
function based on ad->tx_func_type, rather than having a separate vector
flag?
If not, may I suggest that you remove the if condition, and just do:
ad->tx_vec_allowed =
(i40e_tx_path_infos[ad->tx_func_type].features.simd_width < RTE_VECT_SIMD_128);
prev parent reply other threads:[~2025-12-17 15:33 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-12-17 14:54 [PATCH 0/1] " Ciara Loftus
2025-12-17 14:54 ` [PATCH 1/1] " Ciara Loftus
2025-12-17 15:08 ` Bruce Richardson
2025-12-17 15:18 ` Loftus, Ciara
2025-12-17 15:33 ` Bruce Richardson [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=aULNOcN6-wCBIFNY@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).