From patchwork Tue Jul 9 16:19:53 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: David Marchand X-Patchwork-Id: 1129904 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=openvswitch.org (client-ip=140.211.169.12; helo=mail.linuxfoundation.org; envelope-from=ovs-dev-bounces@openvswitch.org; receiver=) Authentication-Results: ozlabs.org; dmarc=fail (p=none dis=none) header.from=redhat.com Received: from mail.linuxfoundation.org (mail.linuxfoundation.org [140.211.169.12]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 45jnmT3MTMz9sBt for ; Wed, 10 Jul 2019 02:27:53 +1000 (AEST) Received: from mail.linux-foundation.org (localhost [127.0.0.1]) by mail.linuxfoundation.org (Postfix) with ESMTP id 327673BE3; Tue, 9 Jul 2019 16:26:48 +0000 (UTC) X-Original-To: dev@openvswitch.org Delivered-To: ovs-dev@mail.linuxfoundation.org Received: from smtp1.linuxfoundation.org (smtp1.linux-foundation.org [172.17.192.35]) by mail.linuxfoundation.org (Postfix) with ESMTPS id DBFB33BD9 for ; Tue, 9 Jul 2019 16:21:13 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by smtp1.linuxfoundation.org (Postfix) with ESMTPS id 7DE26883 for ; Tue, 9 Jul 2019 16:21:13 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id D2B1A3092669; Tue, 9 Jul 2019 16:21:12 +0000 (UTC) Received: from dmarchan.remote.csb (ovpn-204-39.brq.redhat.com [10.40.204.39]) by smtp.corp.redhat.com (Postfix) with ESMTP id DD27188446; Tue, 9 Jul 2019 16:21:00 +0000 (UTC) From: David Marchand To: dev@openvswitch.org Date: Tue, 9 Jul 2019 18:19:53 +0200 Message-Id: <1562689198-21481-1-git-send-email-david.marchand@redhat.com> X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.43]); Tue, 09 Jul 2019 16:21:12 +0000 (UTC) X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on smtp1.linux-foundation.org Cc: i.maximets@samsung.com Subject: [ovs-dev] [PATCH v4 0/5] Quicker pmd threads reloads X-BeenThere: ovs-dev@openvswitch.org X-Mailman-Version: 2.1.12 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: ovs-dev-bounces@openvswitch.org Errors-To: ovs-dev-bounces@openvswitch.org We have been testing the rebalance code in different situations while having traffic going through OVS. Those tests have shown that part of the observed packets losses is due to some time wasted in signaling/waiting for the pmd threads to reload their polling configurations. This series is an attempt at getting pmd threads reloads quicker and more deterministic. Example of number of cycles spent by a pmd between two polling configurations (in cycles minimum/average/maximum of 1000 changes): - cfc06fb13d9c: 141059/332512/6230137 - patch1: 146114/279722/ 721557 - patch2: 46118/176561/ 459963 - patch3: 13878/124914/ 509629 - patch4: 12980/157706/ 509447 - patch5: 12945/ 17715/ 45592 Changelog since v3: - explicitly do not wait for non pmd reload in patch 2 - added Eelco acks Changelog since v2: - remove unneeded synchronisation on pmd thread join in patch 2 Changelog since v1: - incorporated Ilya suggestions in patch 2 and 3 - dropped previous acks on patch 2 and 3 but kept them on patch 4 and 5 since there is no major change in them Changelog since RFC v2: - added ack from Eelco Changelog since RFC v1: - added numbers per patch in cover letter - added memory ordering for explicit synchronisations between threads in patch 1 and patch 2 Acked-by: Ilya Maximets