From: Stephen Hemminger <stephen@networkplumber.org>
To: Thierry Herbelot <thierry.herbelot@6wind.com>
Cc: dev@dpdk.org, Thomas Monjalon <thomas@monjalon.net>,
Devendra Singh Rawat <dsinghrawat@marvell.com>,
Alok Prasad <palok@marvell.com>, Jerin Jacob <jerinj@marvell.com>,
Olivier Matz <olivier.matz@6wind.com>,
Edwin Brossette <edwin.brossette@6wind.com>,
stable@dpdk.org
Subject: Re: [V3] net/qede: reduce the optimization level for gcc > 11
Date: Wed, 10 Sep 2025 09:09:34 -0700 [thread overview]
Message-ID: <20250910090926.204ff85d@hermes.local> (raw)
In-Reply-To: <151c401a-87dc-423c-8bae-89d325dc8c90@6wind.com>
On Wed, 10 Sep 2025 08:49:38 +0200
Thierry Herbelot <thierry.herbelot@6wind.com> wrote:
> Hello Stephen,
>
> On 9/9/25 18:17, Stephen Hemminger wrote:
> > On Tue, 9 Sep 2025 07:40:23 +0200
> > Thierry Herbelot <thierry.herbelot@6wind.com> wrote:
> >
> >> The qede PMD stopped working under Ubuntu-24.04 (using gcc-13) when
> >> compiled with -O3 (default level for all DPDK code). A bug is opened
> >> for this issue (see Link). The same issue is also seen with gcc-12
> >> and gcc-14. The issue is not seen with clang-20.
> >>
> >> A first workaround is to just disable all optimizations (-O0), which
> >> restores packet Rx with Qlogic NICs. However, the performance impact
> >> is not acceptable (around 50% drop).
> >>
> >> A better compromise is to use -O1 for the qede PMD:
> >> - there is some perf impact,
> >> - but the PMD is working as expected (packets are correctly received).
> >>
> >> When compiling with both -O2 and -O3 and gcc > 11, there is no packet
> >> reception when using the qede PMD. The root cause could be missing
> >> 'volatile' keywords or missing memory barriers in the qede PMD code.
> >>
> >> Link: https://bugs.dpdk.org/show_bug.cgi?id=1379
> >> Signed-off-by: Thierry Herbelot <thierry.herbelot@6wind.com>
> >
> > Which rx_burst gets used on that hardware?
> >
> > Is there any indication of errors (like rx_mbuf_alloc_failed) in the stats.
> >
> > The driver does not appear to have any write barrier after updating the consumed packets.
> >
> > Would this help?
> > diff --git a/drivers/net/qede/qede_rxtx.c b/drivers/net/qede/qede_rxtx.c
> > index 25e28fd9f6..1b5109d966 100644
> > --- a/drivers/net/qede/qede_rxtx.c
> > +++ b/drivers/net/qede/qede_rxtx.c
> > @@ -1295,6 +1295,8 @@ static inline void qede_rx_bd_ring_consume(struct qede_rx_queue *rxq)
> > {
> > ecore_chain_consume(&rxq->rx_bd_ring);
> > rxq->sw_rx_cons++;
> > +
> > + rte_wmb();
> > }
> >
> I just checked with this patch, but the error is still present:
>
> testpmd> show fwd stats all
>
> ---------------------- Forward statistics for port 0
> ----------------------
> RX-packets: 0 RX-dropped: 10 RX-total: 10
> RX-error: 0
> RX-nombufs: 10
> TX-packets: 0 TX-dropped: 0 TX-total: 0
>
> ----------------------------------------------------------------------------
>
> The error chain is:
>
> RX-nombufs
> => (testpmd) stats.rx_nombuf
> => (qede) p_stats->common.no_buff_discards
> => (qede/base) HILO_64_REGPAIR(mstats.no_buff_discard)
> (internal to the NIC)
>
Thanks, lets root cause this (rather than paper it over) because
other drivers may have same issue. Since no mbufs are present
looks like rx discriptor never made it to NIC
prev parent reply other threads:[~2025-09-10 16:42 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-09-03 11:32 [PATCH] net/qede: reduce the optimization level Thierry Herbelot
2025-09-06 3:59 ` Stephen Hemminger
2025-09-08 7:04 ` [V2] net/qede: reduce the optimization level for gcc > 11 Thierry Herbelot
2025-09-08 19:59 ` Stephen Hemminger
2025-09-09 5:27 ` Thierry Herbelot
2025-09-09 5:40 ` [V3] " Thierry Herbelot
2025-09-09 16:17 ` Stephen Hemminger
2025-09-10 6:49 ` Thierry Herbelot
2025-09-10 16:09 ` Stephen Hemminger [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=20250910090926.204ff85d@hermes.local \
--to=stephen@networkplumber.org \
--cc=dev@dpdk.org \
--cc=dsinghrawat@marvell.com \
--cc=edwin.brossette@6wind.com \
--cc=jerinj@marvell.com \
--cc=olivier.matz@6wind.com \
--cc=palok@marvell.com \
--cc=stable@dpdk.org \
--cc=thierry.herbelot@6wind.com \
--cc=thomas@monjalon.net \
/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).