Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 1C907C433EF for ; Tue, 9 Nov 2021 14:34:32 +0000 (UTC) Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 9409160D07 for ; Tue, 9 Nov 2021 14:34:31 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org 9409160D07 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=srcf.net Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=lists.xenproject.org Received: from list by lists.xenproject.org with outflank-mailman.223961.386950 (Exim 4.92) (envelope-from ) id 1mkSCW-0003sU-Dp; Tue, 09 Nov 2021 14:34:16 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 223961.386950; Tue, 09 Nov 2021 14:34:16 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1mkSCW-0003sN-Ap; Tue, 09 Nov 2021 14:34:16 +0000 Received: by outflank-mailman (input) for mailman id 223961; Tue, 09 Nov 2021 14:34:15 +0000 Received: from se1-gles-sth1-in.inumbo.com ([159.253.27.254] helo=se1-gles-sth1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1mkSCV-0003sH-BC for xen-devel@lists.xenproject.org; Tue, 09 Nov 2021 14:34:15 +0000 Received: from ppsw-33.csi.cam.ac.uk (ppsw-33.csi.cam.ac.uk [131.111.8.133]) by se1-gles-sth1.inumbo.com (Halon) with ESMTPS id 1b46b8b6-416a-11ec-9787-a32c541c8605; Tue, 09 Nov 2021 15:34:14 +0100 (CET) Received: from hades.srcf.societies.cam.ac.uk ([131.111.179.67]:45654) by ppsw-33.csi.cam.ac.uk (ppsw.cam.ac.uk [131.111.8.137]:25) with esmtps (TLS1.2:ECDHE-RSA-AES256-GCM-SHA384:256) id 1mkSCK-000aIK-hd (Exim 4.95) (return-path ); Tue, 09 Nov 2021 14:34:04 +0000 Received: from [192.168.1.10] (host-92-12-61-86.as13285.net [92.12.61.86]) (Authenticated sender: amc96) by hades.srcf.societies.cam.ac.uk (Postfix) with ESMTPSA id 3D66E1FCD3; Tue, 9 Nov 2021 14:34:04 +0000 (GMT) X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: 1b46b8b6-416a-11ec-9787-a32c541c8605 X-Cam-AntiVirus: no malware found X-Cam-ScannerInfo: https://help.uis.cam.ac.uk/email-scanner-virus Subject: Re: [PATCH for-4.16] Revert "domctl: improve locking during domain destruction" To: Roger Pau Monne , xen-devel@lists.xenproject.org Cc: Andrew Cooper , George Dunlap , Jan Beulich , Julien Grall , Stefano Stabellini , Wei Liu , Hongyan Xia , Dmitry Isaikin , Ian Jackson References: <20211109143128.56089-1-roger.pau@citrix.com> From: Andrew Cooper Message-ID: Date: Tue, 9 Nov 2021 14:34:03 +0000 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.14.0 MIME-Version: 1.0 In-Reply-To: <20211109143128.56089-1-roger.pau@citrix.com> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Content-Language: en-GB On 09/11/2021 14:31, Roger Pau Monne wrote: > This reverts commit 228ab9992ffb1d8f9d2475f2581e68b2913acb88. > > Performance analysis has shown that dropping the domctl lock during > domain destruction greatly increases the contention in the heap_lock, > thus making parallel destruction of domains slower. > > The following lockperf data shows the difference between the current > code and the reverted one: > > lock: 3342357(2.268295505s), block: 3263853(18.556650797s) > lock: 2788704(0.362311723s), block: 222681( 0.091152276s) > > Given the current point in the release, revert the commit and > reinstate holding the domctl lock during domain destruction. Further > work should be done in order to re-add more fine grained locking to > the domain destruction path once a proper solution to avoid the > heap_lock contention is found. > > Reported-by: Hongyan Xia > Reported-by: Dmitry Isaikin > Signed-off-by: Roger Pau Monné Acked-by: Andrew Cooper