From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 0C0ABA0350; Thu, 25 Jun 2020 10:39:09 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id E56811B75C; Thu, 25 Jun 2020 10:39:07 +0200 (CEST) Received: from mga04.intel.com (mga04.intel.com [192.55.52.120]) by dpdk.org (Postfix) with ESMTP id 396D81B5E1 for ; Thu, 25 Jun 2020 10:39:06 +0200 (CEST) IronPort-SDR: 0OZLnMg8turkQ2Kv7kmOS4wbTHYUf32oDTc7b4kaQFwIVDmnCgdOocC7rpHmEE2VIef65OqhNK z/Cjojbn+ftA== X-IronPort-AV: E=McAfee;i="6000,8403,9662"; a="142286843" X-IronPort-AV: E=Sophos;i="5.75,278,1589266800"; d="scan'208";a="142286843" X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga007.fm.intel.com ([10.253.24.52]) by fmsmga104.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 25 Jun 2020 01:39:04 -0700 IronPort-SDR: E8pZ9vt62D+CdqaJdp1HIFl+O5ktNNaQxUPNKfI7ysNjIvZ1Fag53h/ktCwb9JG/bRZfKr8D3v GwIwi56xfuBw== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.75,278,1589266800"; d="scan'208";a="263871789" Received: from orsmsx106.amr.corp.intel.com ([10.22.225.133]) by fmsmga007.fm.intel.com with ESMTP; 25 Jun 2020 01:39:04 -0700 Received: from orsmsx607.amr.corp.intel.com (10.22.229.20) by ORSMSX106.amr.corp.intel.com (10.22.225.133) with Microsoft SMTP Server (TLS) id 14.3.439.0; Thu, 25 Jun 2020 01:39:03 -0700 Received: from orsmsx607.amr.corp.intel.com (10.22.229.20) by ORSMSX607.amr.corp.intel.com (10.22.229.20) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.1713.5; Thu, 25 Jun 2020 01:39:03 -0700 Received: from ORSEDG002.ED.cps.intel.com (10.7.248.5) by orsmsx607.amr.corp.intel.com (10.22.229.20) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256) id 15.1.1713.5 via Frontend Transport; Thu, 25 Jun 2020 01:39:03 -0700 Received: from NAM04-SN1-obe.outbound.protection.outlook.com (104.47.44.51) by edgegateway.intel.com (134.134.137.101) with Microsoft SMTP Server (TLS) id 14.3.439.0; Thu, 25 Jun 2020 01:38:59 -0700 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=hCRmOECslJQKJJlC02POghbWGKOGi/jwqFpFJXkBZ/PgygIDIGWiY/FNV+IJ84EfqkXKfONL7AS3Q8zh594Sz9+jSqm5jhJXCFInb5hlibGOyobN4O3S723CyPOvAxeLmY0QLo71wmGTxbjLS1sIfThfZSNZYpJJlL192N/xuIG0oxcJUlxthqOWz8JX5OZZdItQTe8zH38wgDbLKtw7d0JOWrnjXFVq8V08CbotZGgnueBK3gaeOd4Jox7zTluJJLj8Ng8H9RZIwtmNcpZAtV/14dBnlMoisMdbwLU1AwsGRPhyyWbE/CxbtVsd5uk69DwisfG8vMgulPYhbWXE8A== 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-SenderADCheck; bh=Ohx4EImNLcTxU5SQ49uFVt1/e43Nyq9lTSssqlQrE6o=; b=TNKW95ihKnd4fwAoYIiqBAsuUxzBExlA1D2wvGJTFNQujNu0Txycuzy1rjtlMzHrxLB6Q4nGd4S7lUhN7XB4P+rDa0FXpNxaqrdBIQ85Ig0CwFWWL7QCnWlowlCmLdSL8o8TtgHoTU1EfYHqJ1TcEwo27Mp0OCbd/dVj/BVsTRMsD5QIEuLKbANt6XDXl39VryfY/qos7e/SkvSL2wy6OU16gW2l8d3f2qxGsSjMBraotyevpleSE0rF8/JGpd7j1NTjZbUFaEtkhfwPEqZO8Lz5Xm7P2o/SJRSkJpP5S4WM0wzg6x8wjeEe5MvUKxjd1hWaX/egEhn2maOOs8oISw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=intel.com; dmarc=pass action=none header.from=intel.com; dkim=pass header.d=intel.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=intel.onmicrosoft.com; s=selector2-intel-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=Ohx4EImNLcTxU5SQ49uFVt1/e43Nyq9lTSssqlQrE6o=; b=OG5HJJyY5BO/xKhp3+kk43cfR01DOSqZWs4WliP3Z9TcE9hhAGP9Ft1TTDpqbKueNTyVy6Mx+g17zqeDOTkz+HwTjnkycR0+8DB60Ay+l0DsCOOr3si7P7NuSbfufU8OPa+Zd2CMmiOhrf+KR8zh64NZKGq/NwgMY+SMf2eVDW4= Received: from CY4PR11MB0072.namprd11.prod.outlook.com (10.171.253.27) by CY4PR11MB1462.namprd11.prod.outlook.com (10.172.69.145) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3109.22; Thu, 25 Jun 2020 08:38:58 +0000 Received: from CY4PR11MB0072.namprd11.prod.outlook.com ([fe80::e979:a537:4a97:afd5]) by CY4PR11MB0072.namprd11.prod.outlook.com ([fe80::e979:a537:4a97:afd5%5]) with mapi id 15.20.3131.021; Thu, 25 Jun 2020 08:38:58 +0000 From: "Singh, Jasvinder" To: Thomas Monjalon , "Dumitrescu, Cristian" , Alan Dewar CC: Stephen Hemminger , "dev@dpdk.org" , Alan Dewar Thread-Topic: [dpdk-dev] [PATCH] sched: add 64-bit counter retrieval API Thread-Index: AQHWSnn/PX/abLIe7EGb/KiXFYtrbajpAodw Date: Thu, 25 Jun 2020 08:38:58 +0000 Message-ID: References: <1531925499-938-1-git-send-email-alan.dewar@att.com> <20180723095252.4a93ea91@xeon-e3> <2584526.Ov0XTtHtjM@thomas> In-Reply-To: <2584526.Ov0XTtHtjM@thomas> Accept-Language: en-GB, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: dlp-version: 11.5.1.3 dlp-reaction: no-action dlp-product: dlpe-windows authentication-results: monjalon.net; dkim=none (message not signed) header.d=none;monjalon.net; dmarc=none action=none header.from=intel.com; x-originating-ip: [192.198.151.163] x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: 761249fd-4ce3-4520-1f2f-08d818e3341d x-ms-traffictypediagnostic: CY4PR11MB1462: x-ms-exchange-transport-forked: True x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:10000; x-forefront-prvs: 0445A82F82 x-ms-exchange-senderadcheck: 1 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: R/f2Kx3i3hiTOdVU6uJlyi3Tce91hn2C8n0IUoX9Ncci4lXL8Iwx8C0dskGOgD8AXip1MccGkzB6Bj14RI2XGiqJzWRB806j6UX9mAOwKNG7GAK2IvDZ4o4AZ1jl3W1uit/qhgEzQ/BpUU2Kyccd7iwhkAU+syVx+8VT1cewJZZsK/Ij6dOMa2rljJ1RQNpuKROa8MHfo61Qw+oCgxbupNOvKm/W02p4EQrwdUf7o4A/HhQqFESO7AYlZyf6VgyF1DcBwj1DQUZ2vYUVnoIgny5d9/1HqscAkIuaWzpqhf1sli8lkkXrlXSn8QKMumQh x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:CY4PR11MB0072.namprd11.prod.outlook.com; PTR:; CAT:NONE; SFTY:; SFS:(4636009)(366004)(136003)(346002)(376002)(396003)(39860400002)(66476007)(9686003)(6506007)(53546011)(26005)(110136005)(7696005)(186003)(55016002)(54906003)(71200400001)(5660300002)(8676002)(86362001)(316002)(76116006)(478600001)(4326008)(8936002)(52536014)(64756008)(66946007)(66556008)(66446008)(83380400001)(2906002)(33656002); DIR:OUT; SFP:1102; x-ms-exchange-antispam-messagedata: rKh8dMbfFFORRcaNzZZLacyt+ZzoQ0Iv8ZnzJVo37LhKNVrEP1/RF6rORhPxC6f81vMzRtsMuS8RCvlsIHelwRyRS0FGnUtVnObXo3+7cU69D7qbQfACR+wuqFL0jNJ2FqRMKzsZzL9GxqBPkmtzDaRoWwo466mSVrfFd5dS3cQz0wBMWOKsc5u61guIhyvNOuSlvcZSantsMUlpQ9uqMYsPghSvngFO8Uiwrx0b5GyYlZGy/ig19d+MNKsboK1gWiZtFb1k5OJgxguZjPGOCAm8jJd0sghZEYpy1n8fwXJpAygTkQG/2+txRYzjbFLLv7jHYZsgRhjQI82HmxxJ95ZWGeRWQsqW+yrY6u5EGdKnVsBfH11U9AIbSNDVNRFpbGBZluhxySBis01RjLztr6ZcsVtZ/B8potkvmdE9NGc1QwMB7hN9FEAN0WZF4qteWrChudCVC0350X0cKjKJm3JtBlU0+HReSf0rJa88SdAempQSY3y/ijODtHaYxM4p Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-MS-Exchange-CrossTenant-Network-Message-Id: 761249fd-4ce3-4520-1f2f-08d818e3341d X-MS-Exchange-CrossTenant-originalarrivaltime: 25 Jun 2020 08:38:58.2522 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 46c98d88-e344-4ed4-8496-4ed7712e255d X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: nJt2NSBAjCWGnK8g8K2A6vDOlXnib/4qSDtZxNlLAarM8QdS6BcrvXxWombcFM7ruboNUOWGNuB5dBISsX0ejxCwrg0ljr4jEIXK4m8D0jU= X-MS-Exchange-Transport-CrossTenantHeadersStamped: CY4PR11MB1462 X-OriginatorOrg: intel.com Subject: Re: [dpdk-dev] [PATCH] sched: add 64-bit counter retrieval API X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 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: Thomas Monjalon > Sent: Wednesday, June 24, 2020 11:51 PM > To: Dumitrescu, Cristian ; Alan Dewar > ; Singh, Jasvinder > Cc: Stephen Hemminger ; dev@dpdk.org; > Alan Dewar > Subject: Re: [dpdk-dev] [PATCH] sched: add 64-bit counter retrieval API >=20 > Is this old patch still relevant? >=20 >=20 > 25/07/2018 11:02, Alan Dewar: > > Hi Stephen, > > > > Sorry about the delay in responding to your comment. > > > > Maybe I'm missing something but I don't consider 64-bit counter > > rollover to be a problem. > > The DPDK QoS stats are just 32-bits wide and are zeroed when read. So > > if we read them frequently enough the 32-bit counters won't wrap. > > > > This new API is just a convenient way to read the 32-bit counters into > > variables that are 64-bit wide which allows Vyatta to have a common > > API slightly above the DPDK. > > > > I'd hope that at some point in time the DPDK will move to 64-bit > > counters, but there may be technical reasons why this can't happen > > that I'm not aware of (support for 32-bit CPUs??) > > > > Regards > > Alan > > > > On Mon, Jul 23, 2018 at 5:52 PM, Stephen Hemminger > > wrote: > > > On Wed, 18 Jul 2018 15:51:39 +0100 > > > alangordondewar@gmail.com wrote: > > > > > >> From: Alan Dewar > > >> > > >> Add new APIs to retrieve counters in 64-bit wide fields. > > >> > > >> Signed-off-by: Alan Dewar > > > > > > Do you want to consider 64 bit counter roll over on 32 bit platform? > > > The problem is that incrementing an 64 bit value is not atomic on > > > 32 bit cpu. The carry operation can race with reading. > > > > > > The kernel has special case code to do restartable sequence for > > > accessing 64 bit counter on 32 bit CPU. These functions become nop's > > > on 64bit. > > The stats params have been converted into 64 bit values during library rewo= rk last year. Therefore, patch is not relevant anymore. Thank you, Jasvinder =20