From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id B2C51A034C; Thu, 22 Dec 2022 11:50:58 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 59A79410D0; Thu, 22 Dec 2022 11:50:58 +0100 (CET) Received: from smartserver.smartsharesystems.com (smartserver.smartsharesystems.com [77.243.40.215]) by mails.dpdk.org (Postfix) with ESMTP id 56B2840FDF for ; Thu, 22 Dec 2022 11:50:57 +0100 (CET) Content-class: urn:content-classes:message MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Subject: RE: [PATCH v4 2/6] ethdev: add trace points for ethdev X-MimeOLE: Produced By Microsoft Exchange V6.5 Date: Thu, 22 Dec 2022 11:50:55 +0100 Message-ID: <98CBD80474FA8B44BF855DF32C47DC35D875DB@smartserver.smartshare.dk> In-Reply-To: <20221222063306.3383695-3-adwivedi@marvell.com> X-MS-Has-Attach: X-MS-TNEF-Correlator: Thread-Topic: [PATCH v4 2/6] ethdev: add trace points for ethdev Thread-Index: AdkVz9lQnigIJ0VcRbOjSBdTYMkqygAImbhQ References: <20221006151844.23483-1-adwivedi@marvell.com> <20221222063306.3383695-1-adwivedi@marvell.com> <20221222063306.3383695-3-adwivedi@marvell.com> From: =?iso-8859-1?Q?Morten_Br=F8rup?= To: "Ankur Dwivedi" , , Cc: , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org > From: Ankur Dwivedi [mailto:adwivedi@marvell.com] > Sent: Thursday, 22 December 2022 07.33 >=20 > Adds trace points for ethdev functions. > Moved the rte_ethdev_trace_rx_burst and rte_ethdev_trace_tx_burst to > a new file rte_ethdev_trace_fp_burst.h. This is needed to resolve > cyclic dependency between rte_ethdev.h and rte_ethdev_trace_fp.h. >=20 > Signed-off-by: Ankur Dwivedi > --- > lib/ethdev/ethdev_private.c | 3 + > lib/ethdev/ethdev_trace_points.c | 193 +++++++++++++++++ > lib/ethdev/meson.build | 1 + > lib/ethdev/rte_ethdev.c | 203 ++++++++++++++++-- > lib/ethdev/rte_ethdev.h | 2 +- > lib/ethdev/rte_ethdev_trace.h | 285 = +++++++++++++++++++++++++ > lib/ethdev/rte_ethdev_trace_fp.h | 276 +++++++++++++++++++++++- > lib/ethdev/rte_ethdev_trace_fp_burst.h | 44 ++++ > lib/ethdev/version.map | 66 ++++++ > 9 files changed, 1047 insertions(+), 26 deletions(-) > create mode 100644 lib/ethdev/rte_ethdev_trace_fp_burst.h >=20 > diff --git a/lib/ethdev/ethdev_private.c b/lib/ethdev/ethdev_private.c > index 48090c879a..a8f87f22c1 100644 > --- a/lib/ethdev/ethdev_private.c > +++ b/lib/ethdev/ethdev_private.c > @@ -5,6 +5,7 @@ > #include >=20 > #include "rte_ethdev.h" > +#include "rte_ethdev_trace_fp.h" > #include "ethdev_driver.h" > #include "ethdev_private.h" >=20 > @@ -297,6 +298,7 @@ rte_eth_call_rx_callbacks(uint16_t port_id, > uint16_t queue_id, > cb =3D cb->next; > } >=20 > + rte_eth_trace_call_rx_callbacks(port_id, queue_id, nb_rx, > nb_pkts); Reviewing code like this, it is impossible to determine if this is a = fast path trace or not, without also looking elsewhere. Could we please agree on a naming convention to include _fp in fast path = trace functions and macros? > return nb_rx; > } >=20 > @@ -312,6 +314,7 @@ rte_eth_call_tx_callbacks(uint16_t port_id, > uint16_t queue_id, > cb =3D cb->next; > } >=20 > + rte_eth_trace_call_tx_callbacks(port_id, queue_id, nb_pkts); > return nb_pkts; > } >=20 > diff --git a/lib/ethdev/ethdev_trace_points.c > b/lib/ethdev/ethdev_trace_points.c > index 2919409a15..4fea76e0ff 100644 > --- a/lib/ethdev/ethdev_trace_points.c > +++ b/lib/ethdev/ethdev_trace_points.c > @@ -5,6 +5,7 @@ > #include >=20 > #include > +#include >=20 > RTE_TRACE_POINT_REGISTER(rte_ethdev_trace_configure, > lib.ethdev.configure) > @@ -29,3 +30,195 @@ = RTE_TRACE_POINT_REGISTER(rte_ethdev_trace_rx_burst, >=20 > RTE_TRACE_POINT_REGISTER(rte_ethdev_trace_tx_burst, > lib.ethdev.tx.burst) > + > +RTE_TRACE_POINT_REGISTER(rte_eth_trace_call_rx_callbacks, > + lib.ethdev.call_rx_callbacks) Same comment as above: Reviewing code like this, I cannot immediately = determine if this is fast path trace or not.