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 6EB25A034C; Fri, 9 Dec 2022 02:09:37 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 50ABA40E0F; Fri, 9 Dec 2022 02:09:37 +0100 (CET) Received: from mail-pl1-f178.google.com (mail-pl1-f178.google.com [209.85.214.178]) by mails.dpdk.org (Postfix) with ESMTP id 02F8740E03 for ; Fri, 9 Dec 2022 02:09:35 +0100 (CET) Received: by mail-pl1-f178.google.com with SMTP id y17so3284296plp.3 for ; Thu, 08 Dec 2022 17:09:34 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20210112.gappssmtp.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:subject:cc:to:from:date:from:to:cc:subject:date :message-id:reply-to; bh=Wa2u4cKRLq+n/1j3y7DHnh/aLNMY1hhE6YFVuTieoes=; b=ZQpUcGsgEke8wLjo3IjA2kr3x8ur6qAIwPWvHy6xUvWD8eSUj3amkVF6zd4riVR5b2 GzWNemc6lYjU8fjnPFkgpeHV0unukOeAlWXfVGwAL5xbU9KfmLRStNmQRnnL0s4qTWlh vZLwLY0DWF4Y4RcgC9ajHwbjFx5BvB28ZMI0MbZRG5WVqCmEfiUF5pgxGn0Kz08fu9XU XAfP+uSxm7n5aMSoMvKUZdcdKrTg5rzW0ckq3jT2+ijdYG8QGwEK4BySvCM48TEm/+Wg EInzc1cO7wT6giy1OVWTdC7A7Psn1Z7EdZaUtRzM3sRM50bcTklLSyBEqMoDdyC6IW/1 hm1g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:subject:cc:to:from:date:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=Wa2u4cKRLq+n/1j3y7DHnh/aLNMY1hhE6YFVuTieoes=; b=CgG+Izod2iZOo1nGFuGER3nrkY9jxRazQ5n1AvmfpKbkAotooFYNde37wvek9m/djC PVAz88lpPDNq76UG3urjJpYrjOVP0lrqq77HL8RXqqdZXO2O5LFULvckOVg03vD/+1I9 AGIry8C51OCr8nDMCS7mlmpicvcy2O98erjvl3aQkzOtNAxeh/RgW8kkjAUSBjCNS9eF jjn7yKOTFSl2+HTYn3lJHTx1e39+DcPX5aIqB/dTC2o5ALnNbIfgaOzc0z9fCtC2ISvW 6D5GuINvTiuNgXyy9sQIJkgSxTfxYRNQAlo+FdA/2dOWmid75aCfg1PoiakUWmHhua5l fn9A== X-Gm-Message-State: ANoB5pla7+pv2M72j7A0pDfRdCXj3sQT1A+ZT76pGXqiG0Pm/B78b51H Zj9YqkmGfJYnJywyclyBEb52jA== X-Google-Smtp-Source: AA0mqf5mLjLBDj4Cl7YjTY2MPwUuRUI1L3Sr3xBYwnV+9PZ/nrCH2VQdgMr2Ue9ShDaw665ymhpNsQ== X-Received: by 2002:a17:90a:c396:b0:21d:6327:ab6 with SMTP id h22-20020a17090ac39600b0021d63270ab6mr1790002pjt.1.1670548174183; Thu, 08 Dec 2022 17:09:34 -0800 (PST) Received: from hermes.local (204-195-120-218.wavecable.com. [204.195.120.218]) by smtp.gmail.com with ESMTPSA id js3-20020a17090b148300b002135a57029dsm94409pjb.29.2022.12.08.17.09.33 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 08 Dec 2022 17:09:33 -0800 (PST) Date: Thu, 8 Dec 2022 17:09:32 -0800 From: Stephen Hemminger To: Tyler Retzlaff Cc: dev@dpdk.org, thomas@monjalon.net, david.marchand@redhat.com, olivier.matz@6wind.com, mb@smartsharesystems.com Subject: Re: [PATCH v2 1/3] eal: add rte control thread create API Message-ID: <20221208170932.0ecde4b8@hermes.local> In-Reply-To: <1670347706-23802-2-git-send-email-roretzla@linux.microsoft.com> References: <1670271868-11364-1-git-send-email-roretzla@linux.microsoft.com> <1670347706-23802-1-git-send-email-roretzla@linux.microsoft.com> <1670347706-23802-2-git-send-email-roretzla@linux.microsoft.com> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII 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 On Tue, 6 Dec 2022 09:28:24 -0800 Tyler Retzlaff wrote: > + /* Wait for the control thread to initialize successfully */ > + while ((ctrl_thread_status = > + __atomic_load_n(¶ms->ctrl_thread_status, > + __ATOMIC_ACQUIRE)) == CTRL_THREAD_LAUNCHING) { > + /* Yield the CPU. Using sched_yield call requires maintaining > + * another implementation for Windows as sched_yield is not > + * supported on Windows. > + */ > + rte_delay_us_sleep(1); > + } Would it be worth introducing and using rte_thread_yield(). Rather than waiting 1us which seems like a long time for this.