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 77464A0C41; Wed, 6 Oct 2021 19:26:44 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 665E941171; Wed, 6 Oct 2021 19:26:44 +0200 (CEST) Received: from AZHDRRW-EX02.NVIDIA.COM (azhdrrw-ex02.nvidia.com [20.64.145.131]) by mails.dpdk.org (Postfix) with ESMTP id CACB44114A for ; Wed, 6 Oct 2021 19:26:42 +0200 (CEST) Received: from NAM04-DM6-obe.outbound.protection.outlook.com (104.47.73.47) by mxs.oss.nvidia.com (10.13.234.37) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.858.15; Wed, 6 Oct 2021 10:26:41 -0700 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=nE6xhAwRaS62aMdJhWkIuRs1Vrd95goKOUdSbmabHp69UDpBWygWF9n0HaaZqyTwnL0usppUnn8eLOEsiS8ILsgH7KSo9AdQVXgLarR+jTOaN1+K6vuATnU2TVbMD8XjJClzYTxcXNcg6CaPH37TsPwvZjIX5vtbNJvlhKWDkCidU1Cmqc8SDTAGXz+iuEKydB9FbFBnTtM0amDbX9qstCAB0e96YUr1oPF/YkbnfuW0vg45Wlm0CZiZrQBMSqFnT08UKy/+RlbBi54plOW6r5XC3FokFStwZSVTJIS+CmSioTQ7Ms7jhIthhPqZ1h7IoN1ymsW/esYfN20xXdgcpA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=+oPqVrfoEhDUnf7BuNjF2Mj6WKjoJkcRSMWDbbO4MsU=; b=cEPZT+T22kUozMmI9VGa/vFj3QVYKWkx1jD5R0gBC4UvuyXEzsEGCHQlbj/fLXDJTeWMHvs2LGqAuyHMW4M7hYi/jfrX1gnnCiTOxhdJFlN78YhohXypwKceJ4Q9rmVryk71QwVFH1EV0nIzbDGd/2AdOUjquwVxbK7YAnSlFtU98b8Cd+Wz27gXvfzdxeIY21uLJw0mF+CdRiD4dGIWvtKpkHjXf3UFJPtBNhZL1gCuaKAy0opmfdMwmsSa8awTR+k5CgPMCk+AVyp18f3RxRVohyVgYwOKe9w4XUqt5igLnr2MZhOmZOMNXWwAPJhkagdsOQTmCPpkezTlmcF5zw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=nvidia.com; dmarc=pass action=none header.from=nvidia.com; dkim=pass header.d=nvidia.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=Nvidia.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=+oPqVrfoEhDUnf7BuNjF2Mj6WKjoJkcRSMWDbbO4MsU=; b=V6/Ff9hsLutHZWi6YxtCLlJwRF6Tm9jEu1ucLZAYkv/Civ8p/XGWC4VtKJLinD7R2UhL0zYj8ZMp2Vn4g4hykNjnVV/7Ft4JpFqhQECNm1IUT1IeO1tSmYKmY71dwuQ8jfYJ43KEb7tMPL3EKQCBU1bXRelFRh2j9caCDiEYF3xkyQeEqAegPzw2dH8/H7SxI4gMw83Fm4K5y0tXULR9LaoPJUVXD6lSS56aHLyOuGZhpurr1ViKAjopyJ6nENicJRuu7Ksb/exB7brW6eQrthzLs4Qk7py1+xPbFsUOvq434QRXs9xrlItlFd89WxYnRZTsm30a81aJ4vshwIAMYw== Received: from DM4PR12MB5167.namprd12.prod.outlook.com (2603:10b6:5:396::10) by DM4PR12MB5104.namprd12.prod.outlook.com (2603:10b6:5:393::24) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4566.15; Wed, 6 Oct 2021 17:26:40 +0000 Received: from DM4PR12MB5167.namprd12.prod.outlook.com ([fe80::3c73:8e07:c9ba:f6db]) by DM4PR12MB5167.namprd12.prod.outlook.com ([fe80::3c73:8e07:c9ba:f6db%3]) with mapi id 15.20.4566.022; Wed, 6 Oct 2021 17:26:40 +0000 From: Ali Alnubani To: Konstantin Ananyev , "dev@dpdk.org" CC: "xiaoyun.li@intel.com" , "anoobj@marvell.com" , "jerinj@marvell.com" , "ndabilpuram@marvell.com" , "adwivedi@marvell.com" , "shepard.siegel@atomicrules.com" , "ed.czeck@atomicrules.com" , "john.miller@atomicrules.com" , "irusskikh@marvell.com" , "ajit.khaparde@broadcom.com" , "somnath.kotur@broadcom.com" , "rahul.lakkireddy@chelsio.com" , "hemant.agrawal@nxp.com" , "sachin.saxena@oss.nxp.com" , "haiyue.wang@intel.com" , "johndale@cisco.com" , "hyonkim@cisco.com" , "qi.z.zhang@intel.com" , "xiao.w.wang@intel.com" , "humin29@huawei.com" , "yisen.zhuang@huawei.com" , "oulijun@huawei.com" , "beilei.xing@intel.com" , "jingjing.wu@intel.com" , "qiming.yang@intel.com" , Matan Azrad , Slava Ovsiienko , "sthemmin@microsoft.com" , NBU-Contact-longli , "heinrich.kuhn@corigine.com" , "kirankumark@marvell.com" , "andrew.rybchenko@oktetlabs.ru" , "mczekaj@marvell.com" , "jiawenwu@trustnetic.com" , "jianwang@trustnetic.com" , "maxime.coquelin@redhat.com" , "chenbo.xia@intel.com" , NBU-Contact-Thomas Monjalon , "ferruh.yigit@intel.com" , "mdr@ashroe.eu" , "jay.jayatheerthan@intel.com" Thread-Topic: [dpdk-dev] [PATCH v4 0/7] hide eth dev related structures Thread-Index: AQHXuSfrbAS7YLyeP0+CYU2WV6D+H6vGLrZwgAANC2A= Date: Wed, 6 Oct 2021 17:26:40 +0000 Message-ID: References: <20211001140255.5726-1-konstantin.ananyev@intel.com> <20211004135603.20593-1-konstantin.ananyev@intel.com> In-Reply-To: Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: authentication-results: intel.com; dkim=none (message not signed) header.d=none;intel.com; dmarc=none action=none header.from=nvidia.com; x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: 152e5112-3888-4a6c-f70d-08d988ee7593 x-ms-traffictypediagnostic: DM4PR12MB5104: x-ld-processed: 43083d15-7273-40c1-b7db-39efd9ccc17a,ExtAddr x-ms-exchange-transport-forked: True x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:10000; x-ms-exchange-senderadcheck: 1 x-ms-exchange-antispam-relay: 0 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: P2jgCt1CfHi0ZgIZcC8qIR8R5s/UKEnkRPfZ9VE3kLdqHJQX9QQSl9qB6kf5Gko0G99LLU1he6yhTJWZ+Mp1paAmdHi06U7V4hMziMMmb+4Z2EFaD4yiBdLFNWkQlnCqF1QcsMVMnOj1fjalIiaKh3MrmNk68fvupiFgyM7uxIgztB6RMHExtlWwdRrgenBD2wnizaFQAQRm2uYulVnzyhXjV+a6VUx+honH4TD0q0venx7bHBTUItwKE4KA02c8Mqmr+//Jv+oRkU5v03NU7vLmcrJv6EHJjJ6s4uW7VeXPI2uedrS5Ygh9XYCRNT/gGP5JqBOfrZMGXXYoqhUQlkCwfRglXLvvwvabBsj/lL3ScRB8hegvu2OYTaVJFJ/0fz68iyS5Qgja4Dfg4NBEd9M6qSnj4fOsNWBQWKKSsaNHxQqGqOavJapocS+ANM2nrr7nnYzqG7JO0gonI84eR+3cNesMNEB3TQxviTRQvSoeUcxvAnsZj8y/u5e503CLiOO7YaIzUO84EdqlZ9nRYlsE+Kg/T/cbuApcvP324qAwoWQssoByLu3QwrsVnCliKo1Yh+bPcdicI47+uqADXyNjsjIU+LZWs1CcmeTAseKBXc8gCxoJIveEnLllmSo6kw3jKasfjSGZwrCmfO451ufOpLOGfHmHtWjy+n4mbP3zQlY838HqRM/FeZ+F5EtFiF8SNU85oM/UAkUTpUX5v09G3jLtIVM3MDVDXN9TGFbxZfv3+0Zx8BS/vvei0OCpLVnyK7bHlcWFdzsZGygjdq/x6otqqDRnHZAGd40X09E= x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:DM4PR12MB5167.namprd12.prod.outlook.com; PTR:; CAT:NONE; SFS:(4636009)(366004)(64756008)(45080400002)(966005)(2906002)(83380400001)(6506007)(66446008)(53546011)(76116006)(508600001)(86362001)(66476007)(71200400001)(9686003)(66556008)(55016002)(66946007)(186003)(4326008)(8936002)(52536014)(38100700002)(26005)(38070700005)(33656002)(5660300002)(316002)(110136005)(122000001)(2940100002)(54906003)(8676002)(7696005)(107886003); DIR:OUT; SFP:1101; x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?us-ascii?Q?MQgNSGfGRxKY2rTWEiczhLKD8ZmMojVnTffSA9NhLQJkEaaxfK5J40cX9prt?= =?us-ascii?Q?y66Efosr21ZCAmlFS4NYypr0KeWnp+45Kix7jwkKxn5LSyFdbbcsbFIkuoAn?= =?us-ascii?Q?GAsLPP7Ht17KceHwTRF0MxpySea0NGWXqg7DMIYkJGP+NUqNEOk0+jNx9pti?= =?us-ascii?Q?ndtMTkWSxGTSmawS2BD15R9+Zx76eqzTrDUetGhyv01U6jF2dByB3Pz95SzR?= =?us-ascii?Q?had/3Bur9BfTaturSJxxNjS+PY8e/KFttBpPl+9yjLy5Po1WcFjP3oVvEsH9?= =?us-ascii?Q?xTbxscWjVYtJPXV+maT9f4DPsDifZ/uZtkDlISMw1hg05PiLt5LuUqw5IRK4?= =?us-ascii?Q?n49YSCxb2DOWUIzOoMd2GHchvPtIScZpODaOMcxBvZYsQlPVrCLhJna/q3tG?= =?us-ascii?Q?aq132Hwu1puiEhL2fI+XEaLCLGTyF095lSYK9JC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Q?B5bNo23KH+JuXiaoURGYjcOO?= Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: DM4PR12MB5167.namprd12.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 152e5112-3888-4a6c-f70d-08d988ee7593 X-MS-Exchange-CrossTenant-originalarrivaltime: 06 Oct 2021 17:26:40.4377 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 43083d15-7273-40c1-b7db-39efd9ccc17a X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: gW9CLkORzBoSwIUTZqHdmTWMD/blDIyYxADY8UlHMP2Mb4P4kawIrkIqj8y33HDX8GdF9wSzwkLIN4F1GZ9Amw== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM4PR12MB5104 Subject: Re: [dpdk-dev] [PATCH v4 0/7] hide eth dev related structures 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 Sender: "dev" > -----Original Message----- > From: Ali Alnubani > Sent: Wednesday, October 6, 2021 7:43 PM > To: Konstantin Ananyev ; dev@dpdk.org > Cc: xiaoyun.li@intel.com; anoobj@marvell.com; jerinj@marvell.com; > ndabilpuram@marvell.com; adwivedi@marvell.com; > shepard.siegel@atomicrules.com; ed.czeck@atomicrules.com; > john.miller@atomicrules.com; irusskikh@marvell.com; > ajit.khaparde@broadcom.com; somnath.kotur@broadcom.com; > rahul.lakkireddy@chelsio.com; hemant.agrawal@nxp.com; > sachin.saxena@oss.nxp.com; haiyue.wang@intel.com; johndale@cisco.com; > hyonkim@cisco.com; qi.z.zhang@intel.com; xiao.w.wang@intel.com; > humin29@huawei.com; yisen.zhuang@huawei.com; oulijun@huawei.com; > beilei.xing@intel.com; jingjing.wu@intel.com; qiming.yang@intel.com; > Matan Azrad ; Slava Ovsiienko > ; sthemmin@microsoft.com; NBU-Contact-longli > ; heinrich.kuhn@corigine.com; > kirankumark@marvell.com; andrew.rybchenko@oktetlabs.ru; > mczekaj@marvell.com; jiawenwu@trustnetic.com; > jianwang@trustnetic.com; maxime.coquelin@redhat.com; > chenbo.xia@intel.com; NBU-Contact-Thomas Monjalon > ; ferruh.yigit@intel.com; mdr@ashroe.eu; > jay.jayatheerthan@intel.com > Subject: RE: [dpdk-dev] [PATCH v4 0/7] hide eth dev related structures >=20 > > -----Original Message----- > > From: dev On Behalf Of Konstantin Ananyev > > Sent: Monday, October 4, 2021 4:56 PM > > To: dev@dpdk.org > > Cc: xiaoyun.li@intel.com; anoobj@marvell.com; jerinj@marvell.com; > > ndabilpuram@marvell.com; adwivedi@marvell.com; > > shepard.siegel@atomicrules.com; ed.czeck@atomicrules.com; > > john.miller@atomicrules.com; irusskikh@marvell.com; > > ajit.khaparde@broadcom.com; somnath.kotur@broadcom.com; > > rahul.lakkireddy@chelsio.com; hemant.agrawal@nxp.com; > > sachin.saxena@oss.nxp.com; haiyue.wang@intel.com; > johndale@cisco.com; > > hyonkim@cisco.com; qi.z.zhang@intel.com; xiao.w.wang@intel.com; > > humin29@huawei.com; yisen.zhuang@huawei.com; oulijun@huawei.com; > > beilei.xing@intel.com; jingjing.wu@intel.com; qiming.yang@intel.com; > > Matan Azrad ; Slava Ovsiienko > > ; sthemmin@microsoft.com; NBU-Contact-longli > > ; heinrich.kuhn@corigine.com; > > kirankumark@marvell.com; andrew.rybchenko@oktetlabs.ru; > > mczekaj@marvell.com; jiawenwu@trustnetic.com; > jianwang@trustnetic.com; > > maxime.coquelin@redhat.com; chenbo.xia@intel.com; NBU-Contact- > Thomas > > Monjalon ; ferruh.yigit@intel.com; > mdr@ashroe.eu; > > jay.jayatheerthan@intel.com; Konstantin Ananyev > > > > Subject: [dpdk-dev] [PATCH v4 0/7] hide eth dev related structures > > > > v4 changes: > > - Fix secondary process attach (Pavan) > > - Fix build failure (Ferruh) > > - Update lib/ethdev/verion.map (Ferruh) > > Note that moving newly added symbols from EXPERIMENTAL to DPDK_22 > > section makes checkpatch.sh to complain. > > > > v3 changes: > > - Changes in public struct naming (Jerin/Haiyue) > > - Split patches > > - Update docs > > - Shamelessly included Andrew's patch: > > > > https://patches.dpdk.org/project/dpdk/patch/20210928154856.1015020-1- > > andrew.rybchenko@oktetlabs.ru/ > > into these series. > > I have to do similar thing here, so decided to avoid duplicated effo= rt. > > > > The aim of these patch series is to make rte_ethdev core data > > structures (rte_eth_dev, rte_eth_dev_data, rte_eth_rxtx_callback, > > etc.) internal to DPDK and not visible to the user. > > That should allow future possible changes to core ethdev related > > structures to be transparent to the user and help to improve ABI/API > stability. > > Note that current ethdev API is preserved, but it is a formal ABI break= . > > > > The work is based on previous discussions at: > > https://www.mail-archive.com/dev@dpdk.org/msg211405.html > > https://www.mail-archive.com/dev@dpdk.org/msg216685.html > > and consists of the following main points: > > 1. Copy public 'fast' function pointers (rx_pkt_burst(), etc.) and > > related data pointer from rte_eth_dev into a separate flat array. > > We keep it public to still be able to use inline functions for these > > 'fast' calls (like rte_eth_rx_burst(), etc.) to avoid/minimize slowd= own. > > Note that apart from function pointers itself, each element of this > > flat array also contains two opaque pointers for each ethdev: > > 1) a pointer to an array of internal queue data pointers > > 2) points to array of queue callback data pointers. > > Note that exposing this extra information allows us to avoid extra > > changes inside PMD level, plus should help to avoid possible > > performance degradation. > > 2. Change implementation of 'fast' inline ethdev functions > > (rte_eth_rx_burst(), etc.) to use new public flat array. > > While it is an ABI breakage, this change is intended to be transpare= nt > > for both users (no changes in user app is required) and PMD develope= rs > > (no changes in PMD is required). > > One extra note - with new implementation RX/TX callback invocation > > will cost one extra function call with this changes. That might caus= e > > some slowdown for code-path with RX/TX callbacks heavily involved. > > Hope such trade-off is acceptable for the community. > > 3. Move rte_eth_dev, rte_eth_dev_data, rte_eth_rxtx_callback and > related > > things into internal header: . > > > > That approach was selected to: > > - Avoid(/minimize) possible performance losses. > > - Minimize required changes inside PMDs. > > > > Performance testing results (ICX 2.0GHz, E810 (ice)): > > - testpmd macswap fwd mode, plus > > a) no RX/TX callbacks: > > no actual slowdown observed > > b) bpf-load rx 0 0 JM ./dpdk.org/examples/bpf/t3.o: > > ~2% slowdown > > - l3fwd: no actual slowdown observed > > > > Would like to thank everyone who already reviewed and tested previous > > versions of these series. All other interested parties please don't be > > shy and provide your feedback. > > > > Konstantin Ananyev (7): > > ethdev: allocate max space for internal queue array > > ethdev: change input parameters for rx_queue_count > > ethdev: copy ethdev 'fast' API into separate structure > > ethdev: make burst functions to use new flat array > > ethdev: add API to retrieve multiple ethernet addresses > > ethdev: remove legacy Rx descriptor done API > > ethdev: hide eth dev related structures > > >=20 > Tested single and multi-core packet forwarding performance with testpmd > on both ConnectX-5 and ConnectX-6 Dx. >=20 I should have mentioned that I didn't see any noticeable regressions with t= he cases I mentioned. > Tested-by: Ali Alnubani >=20 > Thanks, > Ali