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 C38CBA0C43; Tue, 31 Aug 2021 00:31:00 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 49E6F40698; Tue, 31 Aug 2021 00:31:00 +0200 (CEST) Received: from EUR05-AM6-obe.outbound.protection.outlook.com (mail-am6eur05on2069.outbound.protection.outlook.com [40.107.22.69]) by mails.dpdk.org (Postfix) with ESMTP id 6E67940042 for ; Tue, 31 Aug 2021 00:30:58 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=armh.onmicrosoft.com; s=selector2-armh-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=Uk5wQbQSa2kUpBXAY4VJfML7Kc7bXDacLPUs7fTvp78=; b=1x23ZyE9NAfaiJ0MC8TJ/qYAxnIgcKWShLeRtAHeWLnGjr7Yi4AVHfkEhfkUL++eTX5ja9MD71FOHRH1H0aVBDK/dHrnLTGtJLZ80agEIiLUmFeVUi5hXut6EqIkRMAWhqc1cjHw5Jdj2jqOtYHsrfEAlx7H/ISm8DyXtEMvWvU= Received: from DB6PR0501CA0045.eurprd05.prod.outlook.com (2603:10a6:4:67::31) by HE1PR08MB2682.eurprd08.prod.outlook.com (2603:10a6:7:39::33) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4457.20; Mon, 30 Aug 2021 22:30:56 +0000 Received: from DB5EUR03FT040.eop-EUR03.prod.protection.outlook.com (2603:10a6:4:67:cafe::7) by DB6PR0501CA0045.outlook.office365.com (2603:10a6:4:67::31) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4457.19 via Frontend Transport; Mon, 30 Aug 2021 22:30:56 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 63.35.35.123) smtp.mailfrom=arm.com; dpdk.org; dkim=pass (signature was verified) header.d=armh.onmicrosoft.com;dpdk.org; dmarc=pass action=none header.from=arm.com; Received-SPF: Pass (protection.outlook.com: domain of arm.com designates 63.35.35.123 as permitted sender) receiver=protection.outlook.com; client-ip=63.35.35.123; helo=64aa7808-outbound-1.mta.getcheckrecipient.com; Received: from 64aa7808-outbound-1.mta.getcheckrecipient.com (63.35.35.123) by DB5EUR03FT040.mail.protection.outlook.com (10.152.20.243) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4457.17 via Frontend Transport; Mon, 30 Aug 2021 22:30:55 +0000 Received: ("Tessian outbound f11f34576ce3:v103"); Mon, 30 Aug 2021 22:30:55 +0000 X-CR-MTA-TID: 64aa7808 Received: from ba310f7ef09f.1 by 64aa7808-outbound-1.mta.getcheckrecipient.com id 8DF95DC7-5298-40B3-8C89-304D0245FD5D.1; Mon, 30 Aug 2021 22:30:46 +0000 Received: from EUR05-AM6-obe.outbound.protection.outlook.com by 64aa7808-outbound-1.mta.getcheckrecipient.com with ESMTPS id ba310f7ef09f.1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384); Mon, 30 Aug 2021 22:30:46 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=XPWv9gVtOrqfRGtzUDIt8dJAcAi+Co9on/KJMcPtZ362PK6yOkJ+lQJ8Z50lUnfRejF/KO5wSOP5uC1SGsu6X3XC4NtZ+sPfp2dPkYe4XJ04xcENDclojjjGfQGzsZKKq8YSXZBiqiLCfgaXVKeyJdququteY1zSLQFW0wJw0rJBU67DzafdW+LfqCAcqE0U8QodgkRTGelc5lCnGQopJ7vDo/Fixu3KZC9Tc+L4FYHkD3bSVQrabgmP8AIymKB6OBlZph+G++7xxjYkFMwvR9eZFvFr0jGeFe9t5NstOelsgvEZ0h8c+gP6wXmQfLbMJOCPq4vHZEWP/cJh5bI8FA== 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=Uk5wQbQSa2kUpBXAY4VJfML7Kc7bXDacLPUs7fTvp78=; b=MA5zLQDmMRhQmrL6n5PincDGMQvFDxtEBC1sX4ZGnT7CqSGcENOWYZT3qSJ1KWb/svM1uF6MszvCj08tikIZwnSxTApCoQ4qmzJmkGxcndcvQGIbNuZ1Rcx+sYhsziGORzkpggtVfc5c3Vlsa6rYv/g9nevpwPKNmIkuLZS1cLd21BtF8Zwi8RMK3uH0ZsAiuuGKTYRyyVH86v26zbfsexgbrvr2wtzxaEBFlmDcxlI7N4cflhyXXRybVOJvcvNNaQ3Fb6jlwdjc6/mq3eT+76MQNXmCLhrQ9zp0h36vjbJWQ4AhGcrNTVOwDIYGlA8ToHVZlBi9YyOJmB9diSbykQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=arm.com; dmarc=pass action=none header.from=arm.com; dkim=pass header.d=arm.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=armh.onmicrosoft.com; s=selector2-armh-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=Uk5wQbQSa2kUpBXAY4VJfML7Kc7bXDacLPUs7fTvp78=; b=1x23ZyE9NAfaiJ0MC8TJ/qYAxnIgcKWShLeRtAHeWLnGjr7Yi4AVHfkEhfkUL++eTX5ja9MD71FOHRH1H0aVBDK/dHrnLTGtJLZ80agEIiLUmFeVUi5hXut6EqIkRMAWhqc1cjHw5Jdj2jqOtYHsrfEAlx7H/ISm8DyXtEMvWvU= Received: from DBAPR08MB5814.eurprd08.prod.outlook.com (2603:10a6:10:1b1::6) by DB7PR08MB3338.eurprd08.prod.outlook.com (2603:10a6:5:1b::22) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4457.18; Mon, 30 Aug 2021 22:30:32 +0000 Received: from DBAPR08MB5814.eurprd08.prod.outlook.com ([fe80::8187:ccbc:30d:3464]) by DBAPR08MB5814.eurprd08.prod.outlook.com ([fe80::8187:ccbc:30d:3464%5]) with mapi id 15.20.4457.024; Mon, 30 Aug 2021 22:30:32 +0000 From: Honnappa Nagarahalli To: Stephen Hemminger CC: Olivier Matz , "dev@dpdk.org" , "lucp.at.work@gmail.com" , "david.marchand@redhat.com" , "thomas@monjalon.net" , Ruifeng Wang , nd , nd Thread-Topic: [dpdk-dev] [RFC v2] eal: simplify the implementation of rte_ctrl_thread_create Thread-Index: AQHXmAf2H4CM5JFQ9Uaq02hO5DyJ6quDDf+wgAAgmACACX4AYA== Date: Mon, 30 Aug 2021 22:30:31 +0000 Message-ID: References: <20210730213709.19400-1-honnappa.nagarahalli@arm.com> <20210802051652.3611-1-honnappa.nagarahalli@arm.com> <20210824143058.45b31118@hermes.local> In-Reply-To: <20210824143058.45b31118@hermes.local> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-ts-tracking-id: 90A4EF01A64FB841B1CDCFAB43D25A9A.0 x-checkrecipientchecked: true Authentication-Results-Original: networkplumber.org; dkim=none (message not signed) header.d=none;networkplumber.org; dmarc=none action=none header.from=arm.com; x-ms-publictraffictype: Email X-MS-Office365-Filtering-Correlation-Id: 38566fa6-30d1-4def-e684-08d96c05d558 x-ms-traffictypediagnostic: DB7PR08MB3338:|HE1PR08MB2682: x-ld-processed: f34e5979-57d9-4aaa-ad4d-b122a662184d,ExtAddr x-ms-exchange-transport-forked: True X-Microsoft-Antispam-PRVS: x-checkrecipientrouted: true nodisclaimer: true x-ms-oob-tlc-oobclassifiers: OLM:9508;OLM:9508; X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam-Untrusted: BCL:0; X-Microsoft-Antispam-Message-Info-Original: tvOM0LmC9gqw22Lcq0svC6fhZHsXffqpWnJ+hcIs+25EpwzE1PkTcpS2xS0+wWYmxBOh8WmyVGW6VMhoUVtvlJ4taGukrGJENtv6Z4hTC7fGPNurPhaOenSZeHFThpLUbfKkHBJE7NzOWEc6WI88ExWxBL4iH5BJsI0k10IDO753nS9KoOw9EX9LB683YJ0ovqqsiO9MJ5UGSmrv5WeAe26kpFEQe3abjwz3MWE3uZv3ITZT+UdTUL4sYTzaPRfweMwYBRapLTFSXV0CTEvRPGFi/M9X86rOay4nkUJusFLQYRm8DdEDyjh/MfgOXQiNcdM0jw3FtEwPfvcsozfK3jUnzlJhn9ZV/NkP2XLd970QiIiSjGmNzuxZXrDz7JU3KU2PKiM0t44cVjfTFgw+epzOoY7UboO2tlMSZ/EAmtL43AhvHrbRcUe51NCWeQ9qQOp7S+lsDB6b5e476s42UEpiC8kRcvMERNoiIT9Tp8XE9cGQ8umPABvP7E74Thuzq+BnXZlv3xl4cozcUyfsDFvneSHa2y9zJVKjXQTx0l64RugYAWdBeVX+Oj/ThLoVDMk/6YnzrEe7jpUB2j8kopU8vXL4pgR17kjUWuvNPpcgWTI+pdfgRcno9gNx7gmqM0mHPahk45vdaIFPQwtoJKWk2rFLAt41iVpYf40YjbTNZnVXRHaPJvazoOopc5nbUcNFUIAyZP6o+lzKNDBLLw== X-Forefront-Antispam-Report-Untrusted: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:DBAPR08MB5814.eurprd08.prod.outlook.com; PTR:; CAT:NONE; SFS:(4636009)(366004)(316002)(38100700002)(54906003)(7696005)(5660300002)(4326008)(122000001)(2906002)(508600001)(86362001)(186003)(9686003)(71200400001)(38070700005)(66946007)(33656002)(55016002)(6506007)(8676002)(64756008)(8936002)(66556008)(4744005)(66476007)(66446008)(26005)(52536014)(76116006)(6916009); DIR:OUT; SFP:1101; x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?us-ascii?Q?Zfgln+cEiZZn+4EHh8LAOCbNMJZ0jsYVJUXIe/KlbW2y0DDQL/QnqGNowiKh?= =?us-ascii?Q?up4SDrkIJuFYV+087rr/Qcdm0vo5W9XqBWzXQmyowkX/Ue6j1JDsv881jzMJ?= =?us-ascii?Q?yKGxcv4zSa+3SW9zRh4KNSMoE4vMLzCBSMvrLNNwJofRHXYpICDw5gr+nQeT?= =?us-ascii?Q?4cChQyCSDwvHpbABpEQns5+wqjpHbgOT1nkhqS0NES7QvOFvMalgKsKK6mfe?= =?us-ascii?Q?G4LkI1Lz8GNr0XdKwqN5Q1OMl87iMmT6r5AeVKGKuOMIpK7hWqLNEGqVLOG3?= =?us-ascii?Q?uspancQXkHyU0B51qB8ZloqS1cPx8QfJ1Xm7dtb4Ji6tZOtx4CYY8NneUqKZ?= =?us-ascii?Q?MYME/BRDac+jt+4xx5xKK//p9VIeAMc03Fpk5KvZ5z5dMhcDVs3JAzUC0lxG?= =?us-ascii?Q?SLOSMT0dKXWCIn8pkF1fEGfE+WDFvLpbepyF24rI1J9GXTinURmghlNiiK72?= =?us-ascii?Q?ttCht386UJSQN2zA+cuZbYnPoJ+WHJRX/diZJNlxMyHgFfLkMRAZkxNHM243?= =?us-ascii?Q?zaeWZueoZnFEYdm/Jk4BRLTSsi6rkyesWDWU1qbZeHi5KfX0cIhw35Dkpewr?= =?us-ascii?Q?ifSxJF2Q4xey5IwJds/3aolkLJApm8VU5QZxQkMttWDKJxF8qO3ywqesltlK?= =?us-ascii?Q?g203VVvMzWA0OPss47CfoA+0vBI6AO9LAPIhtV/EnCh7wTDQayLVo16D0QeV?= =?us-ascii?Q?+budECVsrTeFNSSIxFPGAcovkcOQ5TxF1DgLCiCwoX0Vc9D4I4GipH+s38N9?= =?us-ascii?Q?Ox4g05vmRd6YHls9kZbYZXnZfXm+0h3btNbDHR8DDSZt8er22AnatLd/ZX0j?= =?us-ascii?Q?aLxK1aX75Id+hPIixJQOs25VhEEroXvd+ipl/mbFUnzdHe0/iKhPLhtyIJBM?= =?us-ascii?Q?U4diagiauVHdAeMFdArUyAlJd5XzNN3b6ZyI3zVWWDpumpKnu8R6EGwzl/er?= =?us-ascii?Q?myGeG7peRuoETfyBOumAkf/u0Gftb+sTJBc1HYLRu4Ag37suLHLPJIv+HUsG?= =?us-ascii?Q?J5WOO8U8iJ5G1yndqEdrrQymdQoZCEJ9ZVMfJGMBeo1g3DjtGanlJ0kBcwOO?= =?us-ascii?Q?fykbXGOmmRthtq8cQpqkqUKMtdL9wlTFJDlyde7eyNCi1Id3aQSYjtbgWZUx?= =?us-ascii?Q?kJ5VbV0rlbogFheEJFWquxTBFbd8r0MTMJX8uyEXp4wmTyyziCQ+rOjPRtDR?= =?us-ascii?Q?kt0tIMx7fS5NrVYmBVfD4odR8/J/QA/id4o7FQ4g5jxWZ4rHKO+1h+V+5LZq?= =?us-ascii?Q?PF7xpeVdeSpm7rPL8HDE/z29ZQioBmKV0htoyaF5u5y+AgsIxGN1rRDjq11Q?= =?us-ascii?Q?dKqjxB7zfE2D5n8/2QN3cfZj?= Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB7PR08MB3338 Original-Authentication-Results: networkplumber.org; dkim=none (message not signed) header.d=none; networkplumber.org; dmarc=none action=none header.from=arm.com; X-EOPAttributedMessage: 0 X-MS-Exchange-Transport-CrossTenantHeadersStripped: DB5EUR03FT040.eop-EUR03.prod.protection.outlook.com X-MS-Office365-Filtering-Correlation-Id-Prvs: 3e6be1f0-3b1f-43cc-9279-08d96c05c712 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: FdGhLzrkvjfRTJbRR21aud0y0YgL4UQ6jZrbAMvahOU04rmortGYLIrHAWdXR7hzPK2Yl/FsNRzYNhmgBSHYQHK42tY3qT/k7FRWNJW91MWrfWKHqE1rPawBBdSI+JxtcP7J9xgjQzlMgIrHBGWHhrqcktBWp14SvrBwiwa86bKaieN4e4uowEjjqQt38/HF+zsQbkdVAqaNCibeLPi9s1ROU3YYyroTRXWEzHDGLn+nYQcibVzO/PoKi/ux1J3wZaUiBh7iJ2c66TPmzJ92aF/6TEEg7A5+rJd8fNwc+yysbKM9Cma61D6M9ahkSJLDab1T1hHKu7vWk/2jZcUj0Cmh0ByDUmMsHM6TP8ijEQgt+6mbIQOM6Gka0gT6W8i+spqTOgw1mZ2u6qDHnzoD4OiHhJxfQyDVSmczfj2PdS9p+ws0UFUaaxVuDlLdp2Hj9bE4+awQR1m23xwAjgFKE+T5mYn16p++8xUzmYk0/Hm1sUYES35dquKDbOwQ/B+Ie8SRzEJQDQMlGB6w/GFEGQskepT4SKj3mYZvWK8DeDbv1qL6e2ukxUXPPqQhQNwVoxUddxVZenRkmQAvIBn181Nct9w9GDRaVTZ1Bdeg3PHWNSbTC0N46LF6HufMazWknoR/GqD7ov5xmREPbShWdNYQts7v4b0CkcE/+5nGLJ9ukMB300s2kj0mc056a2QI0U3flgYT/AaHmuV0rVDASw== X-Forefront-Antispam-Report: CIP:63.35.35.123; CTRY:IE; LANG:en; SCL:1; SRV:; IPV:CAL; SFV:NSPM; H:64aa7808-outbound-1.mta.getcheckrecipient.com; PTR:ec2-63-35-35-123.eu-west-1.compute.amazonaws.com; CAT:NONE; SFS:(4636009)(346002)(136003)(396003)(376002)(39860400002)(36840700001)(46966006)(6506007)(356005)(5660300002)(82310400003)(2906002)(52536014)(4326008)(316002)(47076005)(8936002)(4744005)(478600001)(81166007)(33656002)(8676002)(70586007)(186003)(336012)(70206006)(55016002)(36860700001)(82740400003)(86362001)(7696005)(6862004)(26005)(54906003)(9686003); DIR:OUT; SFP:1101; X-OriginatorOrg: arm.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 30 Aug 2021 22:30:55.9565 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 38566fa6-30d1-4def-e684-08d96c05d558 X-MS-Exchange-CrossTenant-Id: f34e5979-57d9-4aaa-ad4d-b122a662184d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=f34e5979-57d9-4aaa-ad4d-b122a662184d; Ip=[63.35.35.123]; Helo=[64aa7808-outbound-1.mta.getcheckrecipient.com] X-MS-Exchange-CrossTenant-AuthSource: DB5EUR03FT040.eop-EUR03.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: HE1PR08MB2682 Subject: Re: [dpdk-dev] [RFC v2] eal: simplify the implementation of rte_ctrl_thread_create 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" >=20 > On Tue, 24 Aug 2021 20:03:03 +0000 > Honnappa Nagarahalli wrote: >=20 > > > One difference between this implementation and the previous one is > > > this busy loop. rte_pause() relaxes the cpu, but will not make the > > > calling thread to sleep and wait for the sync event. So here we can > > > spin a quite long time until the other thread is scheduled by the OS. > > Yes, this is a difference. We could add a microsleep to allow for the O= S to un- > schedule the current thread. >=20 > Why not use sched_yield() here? This means, it is not portable to Windows. The function needs to be moved t= o OS specific files. Are there any guidelines on creating OS specific funct= ions? Can I create in this case?