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 49943A00C2; Thu, 6 Oct 2022 09:50:48 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 3E6C242B8D; Thu, 6 Oct 2022 09:50:48 +0200 (CEST) Received: from shelob.oktetlabs.ru (shelob.oktetlabs.ru [91.220.146.113]) by mails.dpdk.org (Postfix) with ESMTP id AFF2041153 for ; Thu, 6 Oct 2022 09:50:46 +0200 (CEST) Received: from [192.168.38.17] (aros.oktetlabs.ru [192.168.38.17]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by shelob.oktetlabs.ru (Postfix) with ESMTPSA id E087C86; Thu, 6 Oct 2022 10:50:45 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 shelob.oktetlabs.ru E087C86 DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=oktetlabs.ru; s=default; t=1665042645; bh=COYVYiRVuABGDXaXomumkKNlS1mb3f/ivEu1lBnZAt4=; h=Date:Subject:To:Cc:References:From:In-Reply-To:From; b=wZeEzwkSAdNUklA152c/PiuuNc/HwxBEWnvwyD+e3A7qF8N8FsPKkL2Hgvc29/zFV kcQRhKd0S4hJ2xidljbReK4i40B70bJdd894WbJ0zXTTERLszzVg2igHzaONXJqxwQ OOjAtlc+PF8ijByS17+y3sjk89eyxK9t3CrKGgf4= Message-ID: Date: Thu, 6 Oct 2022 10:50:45 +0300 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.3.0 Subject: Re: [EXT] Re: [PATCH v2 1/4] ethdev: add trace points Content-Language: en-US To: Ankur Dwivedi , "dev@dpdk.org" , "david.marchand@redhat.com" Cc: Thomas Monjalon , Ferruh Yigit , Jerin Jacob Kollanukkaran References: <20220804134430.6192-1-adwivedi@marvell.com> <20220929102936.5490-1-adwivedi@marvell.com> <20220929102936.5490-2-adwivedi@marvell.com> <6bee8943-408e-a930-f053-541af8bed6d0@oktetlabs.ru> <7369fc89-6588-8898-ed2d-91329248e2b6@oktetlabs.ru> From: Andrew Rybchenko Organization: OKTET Labs In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit 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 @David, see small question below. @Thomas, @Ferruh, @Jerin see question below as well. On 10/6/22 10:43, Ankur Dwivedi wrote: > > >> -----Original Message----- >> From: Andrew Rybchenko >> Sent: Thursday, October 6, 2022 12:58 PM >> To: Ankur Dwivedi ; dev@dpdk.org >> Cc: thomas@monjalon.net; mdr@ashroe.eu; orika@nvidia.com; >> ferruh.yigit@xilinx.com; chas3@att.com; humin29@huawei.com; >> linville@tuxdriver.com; ciara.loftus@intel.com; qi.z.zhang@intel.com; >> mw@semihalf.com; mk@semihalf.com; shaibran@amazon.com; >> evgenys@amazon.com; igorch@amazon.com; chandu@amd.com; Igor >> Russkikh ; shepard.siegel@atomicrules.com; >> ed.czeck@atomicrules.com; john.miller@atomicrules.com; >> ajit.khaparde@broadcom.com; somnath.kotur@broadcom.com; Jerin Jacob >> Kollanukkaran ; Maciej Czekaj [C] >> ; Shijith Thotton ; >> Srisivasubramanian Srinivasan ; Harman Kalra >> ; rahul.lakkireddy@chelsio.com; johndale@cisco.com; >> hyonkim@cisco.com; liudongdong3@huawei.com; >> yisen.zhuang@huawei.com; xuanziyang2@huawei.com; >> cloud.wangxiaoyun@huawei.com; zhouguoyang@huawei.com; >> simei.su@intel.com; wenjun1.wu@intel.com; qiming.yang@intel.com; >> Yuying.Zhang@intel.com; beilei.xing@intel.com; xiao.w.wang@intel.com; >> jingjing.wu@intel.com; junfeng.guo@intel.com; rosen.xu@intel.com; Nithin >> Kumar Dabilpuram ; Kiran Kumar Kokkilagadda >> ; Sunil Kumar Kori ; Satha >> Koteswara Rao Kottidi ; Liron Himi >> ; zr@semihalf.com; Radha Chintakuntla >> ; Veerasenareddy Burru ; >> Sathesh B Edara ; matan@nvidia.com; >> viacheslavo@nvidia.com; sthemmin@microsoft.com; longli@microsoft.com; >> spinler@cesnet.cz; chaoyong.he@corigine.com; >> niklas.soderlund@corigine.com; hemant.agrawal@nxp.com; >> sachin.saxena@oss.nxp.com; g.singh@nxp.com; apeksha.gupta@nxp.com; >> sachin.saxena@nxp.com; aboyer@pensando.io; Rasesh Mody >> ; Shahed Shaikh ; Devendra >> Singh Rawat ; jiawenwu@trustnetic.com; >> jianwang@trustnetic.com; jbehrens@vmware.com; >> maxime.coquelin@redhat.com; chenbo.xia@intel.com; >> steven.webster@windriver.com; matt.peters@windriver.com; >> bruce.richardson@intel.com; mtetsuyah@gmail.com; grive@u256.net; >> jasvinder.singh@intel.com; cristian.dumitrescu@intel.com; >> jgrajcia@cisco.com >> Subject: Re: [EXT] Re: [PATCH v2 1/4] ethdev: add trace points >> >> On 10/6/22 10:24, Ankur Dwivedi wrote: >>> Hi Andrew, >>> >>>> -----Original Message----- >>>> From: Andrew Rybchenko >>>> Sent: Thursday, October 6, 2022 12:40 PM >>>> To: Ankur Dwivedi ; dev@dpdk.org >>>> Cc: thomas@monjalon.net; mdr@ashroe.eu; orika@nvidia.com; >>>> ferruh.yigit@xilinx.com; chas3@att.com; humin29@huawei.com; >>>> linville@tuxdriver.com; ciara.loftus@intel.com; qi.z.zhang@intel.com; >>>> mw@semihalf.com; mk@semihalf.com; shaibran@amazon.com; >>>> evgenys@amazon.com; igorch@amazon.com; chandu@amd.com; Igor >> Russkikh >>>> ; shepard.siegel@atomicrules.com; >>>> ed.czeck@atomicrules.com; john.miller@atomicrules.com; >>>> ajit.khaparde@broadcom.com; somnath.kotur@broadcom.com; Jerin >> Jacob >>>> Kollanukkaran ; Maciej Czekaj [C] >>>> ; Shijith Thotton ; >>>> Srisivasubramanian Srinivasan ; Harman Kalra >>>> ; rahul.lakkireddy@chelsio.com; >>>> johndale@cisco.com; hyonkim@cisco.com; liudongdong3@huawei.com; >>>> yisen.zhuang@huawei.com; xuanziyang2@huawei.com; >>>> cloud.wangxiaoyun@huawei.com; zhouguoyang@huawei.com; >>>> simei.su@intel.com; wenjun1.wu@intel.com; qiming.yang@intel.com; >>>> Yuying.Zhang@intel.com; beilei.xing@intel.com; xiao.w.wang@intel.com; >>>> jingjing.wu@intel.com; junfeng.guo@intel.com; rosen.xu@intel.com; >>>> Nithin Kumar Dabilpuram ; Kiran Kumar >>>> Kokkilagadda ; Sunil Kumar Kori >>>> ; Satha Koteswara Rao Kottidi >>>> ; Liron Himi ; >>>> zr@semihalf.com; Radha Chintakuntla ; >>>> Veerasenareddy Burru ; Sathesh B Edara >>>> ; matan@nvidia.com; viacheslavo@nvidia.com; >>>> sthemmin@microsoft.com; longli@microsoft.com; spinler@cesnet.cz; >>>> chaoyong.he@corigine.com; niklas.soderlund@corigine.com; >>>> hemant.agrawal@nxp.com; sachin.saxena@oss.nxp.com; >> g.singh@nxp.com; >>>> apeksha.gupta@nxp.com; sachin.saxena@nxp.com; aboyer@pensando.io; >>>> Rasesh Mody ; Shahed Shaikh >>>> ; Devendra Singh Rawat >>>> ; jiawenwu@trustnetic.com; >>>> jianwang@trustnetic.com; jbehrens@vmware.com; >>>> maxime.coquelin@redhat.com; chenbo.xia@intel.com; >>>> steven.webster@windriver.com; matt.peters@windriver.com; >>>> bruce.richardson@intel.com; mtetsuyah@gmail.com; grive@u256.net; >>>> jasvinder.singh@intel.com; cristian.dumitrescu@intel.com; >>>> jgrajcia@cisco.com >>>> Subject: [EXT] Re: [PATCH v2 1/4] ethdev: add trace points >>>> >>>> External Email >>>> >>>> --------------------------------------------------------------------- >>>> - On 9/29/22 13:29, Ankur Dwivedi wrote: >>>>> Add trace points for ethdev functions. >>>>> >>>>> Signed-off-by: Ankur Dwivedi >>>> >>>> [snip] >>>> >>>>> @@ -5867,6 +6010,7 @@ rte_eth_rx_metadata_negotiate(uint16_t >>>>> port_id, >>>> uint64_t *features) >>>>> { >>>>> struct rte_eth_dev *dev; >>>>> >>>>> + rte_eth_trace_rx_metadata_negotiate(port_id, features); >>>> >>>> features are in/out, so it would be interesting to values, not just >>>> pointer and both values: input and output. >>> [Ankur] Will add a emit line to display the uint64_t input value of features. >> >> What about output? > [Ankur] The output is not captured because it calls a callback in the return: > > return eth_err(port_id, (*dev->dev_ops->rx_metadata_negotiate)(dev, features)); > > I do not wanted to modify the existing code/logic for trace. OK, I see the reason now. I'd like to hear opinion of other ethdev maintainers (@Thomas and @Ferruh) and @Jerin. Thoughts? It is just one example from many-many cases. The question is how pedantic should we be with added tracing? >> >>>> >>>>> RTE_ETH_VALID_PORTID_OR_ERR_RET(port_id, -ENODEV); >>>>> dev = &rte_eth_devices[port_id]; >>>>> >>>> >>>> [snip] >>>> >>>>> diff --git a/lib/ethdev/version.map b/lib/ethdev/version.map index >>>>> 3def7bfd24..e3d603cc9a 100644 >>>>> --- a/lib/ethdev/version.map >>>>> +++ b/lib/ethdev/version.map >>>>> @@ -288,6 +288,150 @@ EXPERIMENTAL { >>>>> >>>>> # added in 22.11 >>>>> rte_flow_async_action_handle_query; >>>>> + __rte_eth_trace_add_first_rx_callback; >>>> >>>> Why is it in EXPERIMENTAL section, but not INTERNAL? >>> [Ankur] Because the functions for which trace is added are not internal >> functions. >> >> Sorry, but I don't understand. I agree that tracing of public inline functions >> must be part of ABI, but why everything else should be a part of ABI? > [Ankur] I see that there are some already existing trace functions added in EXPERIMENTAL in version.map like __rte_ethdev_trace_configure, __rte_ethdev_trace_rxq_setup. So not sure will it be internal or experimental. > > But you are right the trace function will not be called as a public api. Should I make the newly added trace as internal then? @David, do I understand correctly that trace points in EXPERIMENTAL is a mistake in majority of cases? >> >>>> >>>> [snip] >>>> >>>>> INTERNAL >