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 ABD90A0524; Mon, 19 Apr 2021 20:13:50 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 315D241439; Mon, 19 Apr 2021 20:13:50 +0200 (CEST) Received: from out1-smtp.messagingengine.com (out1-smtp.messagingengine.com [66.111.4.25]) by mails.dpdk.org (Postfix) with ESMTP id E7103413DE for ; Mon, 19 Apr 2021 20:13:48 +0200 (CEST) Received: from compute1.internal (compute1.nyi.internal [10.202.2.41]) by mailout.nyi.internal (Postfix) with ESMTP id 9224B5C010D; Mon, 19 Apr 2021 14:13:48 -0400 (EDT) Received: from mailfrontend1 ([10.202.2.162]) by compute1.internal (MEProxy); Mon, 19 Apr 2021 14:13:48 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=monjalon.net; h= from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding:content-type; s=fm1; bh= Vv5wEB9cGKlQYt5Pi5huxoi7PWdSkrP/DX2y6HqTqRY=; b=Vux0Q4zuHzQG1Ajc FiSrbrVE6LZn8v8JysA4NbE1EshFMJPkF+rWWtKK7ddQjQ+Eh8CFq5YQfzAUPE0M FpZ11rsDnyHW0txKdrMb/G2hYmac1GcGkQUYA75FmvvptCy7Hn7s7806latDs0g8 l8i+VS0gEdUvt6kkZFWPhwLekymre/sJw9hI4rSDb5BDHWnlMkmRoERIdsevb+fT pi87Ua1FFzTm8AqmSLSE65F0CNZiV5D62bkhwJ/0Q5SLB/5V6XPShoGH8mrqBl94 BDNgbXRUbrl7U/xbVmIKPHKIIlVO0Bju8V6f36pRfrBnLWcuYpOU9xBmrSBDTZfF IsRZgg== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender :x-sasl-enc; s=fm2; bh=Vv5wEB9cGKlQYt5Pi5huxoi7PWdSkrP/DX2y6HqTq RY=; b=O1KAQzIu/A140A4B/FguRdjAt8myqbAH3xokJYF4D0zAAkwA2QR6Mkfa3 cvUHTYaVnc38VMPOh2n5Oh1PZrj9Km2WULz3Zh6AvNyQl71ADDH4I0LAYJhM5UIh wx8T34k8EGcZoaH5WNL+PocMakBF6HTJp6vG3hGJ9unECB86SCbcggDVLjaITmc8 B5G/yQajn3K7lz1cU4GN0le7X23J+iZA+G166oDjktliTrTkLJKpPHyVCIGJ6gJM w2QnIQXXbNbi7lDNT30sFO4XYW6bJ2UOw8tf5M6VvXaqETpoYmSRTIr+GRl0Hc7m /AxnTQfygBNZ9evPTZY9uFDOP8CFA== X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeduledrvddtgedguddvgecutefuodetggdotefrod ftvfcurfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfgh necuuegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmd enucfjughrpefhvffufffkjghfggfgtgesthfuredttddtvdenucfhrhhomhepvfhhohhm rghsucfoohhnjhgrlhhonhcuoehthhhomhgrshesmhhonhhjrghlohhnrdhnvghtqeenuc ggtffrrghtthgvrhhnpedugefgvdefudfftdefgeelgffhueekgfffhfeujedtteeutdej ueeiiedvffegheenucfkphepjeejrddufeegrddvtdefrddukeegnecuvehluhhsthgvrh fuihiivgeptdenucfrrghrrghmpehmrghilhhfrhhomhepthhhohhmrghssehmohhnjhgr lhhonhdrnhgvth X-ME-Proxy: Received: from xps.localnet (184.203.134.77.rev.sfr.net [77.134.203.184]) by mail.messagingengine.com (Postfix) with ESMTPA id C271924005A; Mon, 19 Apr 2021 14:13:46 -0400 (EDT) From: Thomas Monjalon To: Jie Zhou Cc: Tal Shnaiderman , "dev@dpdk.org" , "dmitry.kozliuk@gmail.com" , "xiaoyun.li@intel.com" , "roretzla@microsoft.com" , "pallavi.kadam@intel.com" , "bruce.richardson@intel.com" , "ferruh.yigit@intel.com" , david.marchand@redhat.com Date: Mon, 19 Apr 2021 20:13:45 +0200 Message-ID: <3990047.YzQW8q25Qq@thomas> In-Reply-To: <20210419180422.GA19684@linuxonhyperv3.guj3yctzbm1etfxqx2vob5hsef.xx.internal.cloudapp.net> References: <1618594501-23795-10-git-send-email-jizh@linux.microsoft.com> <20210419180422.GA19684@linuxonhyperv3.guj3yctzbm1etfxqx2vob5hsef.xx.internal.cloudapp.net> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" Subject: Re: [dpdk-dev] [PATCH v5 5/9] app/testpmd: add clock_gettime_monotonic 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" 19/04/2021 20:04, Jie Zhou: > On Sun, Apr 18, 2021 at 05:20:42PM +0000, Tal Shnaiderman wrote: > > > --- a/app/test-pmd/config.c > > > +++ b/app/test-pmd/config.c > > > @@ -63,6 +63,12 @@ > > > > > > #define NS_PER_SEC 1E9 > > > > > > +#ifdef RTE_EXEC_ENV_WINDOWS > > > +#define _clock_gettime_monotonic(cur_time) > > > +clock_gettime_monotonic(&cur_time) > > > +#else > > > +#define _clock_gettime_monotonic(cur_time) > > > clock_gettime(CLOCK_TYPE_ID, > > > +&cur_time) #endif > > > + > > > > I think this change should be in EAL: > > rte_get_time_monotonic(&cur_time) > > > > Windows implementation in windows\eal_timer.c > > Unix implementation in unix\eal_unix_timer.c > > Originally and internally, the function was added into eal. But then restricted the functionality just inside testpmd to avoid currently seems unnecessary version change, per a discussion in community meeting several weeks back. If we believe eal support of clock_gettime for windows will benefit other drivers/apps now instead of future when real need comes up, I can move it back into eal. DmitryK and Tyler, any conern or inputs here? My point of view: A test application is also testing the API availability. Here it shows something is missing in EAL. Instead of workarounding in the test application, it should direct you to fixing EAL. I don't know who decided to take this shortcut, but it should be considered as an exception, and accepted only if improving EAL is really difficult.