From mboxrd@z Thu Jan 1 00:00:00 1970 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 kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 53F94C54EE9 for ; Fri, 2 Sep 2022 07:43:21 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 38ED0800CC; Fri, 2 Sep 2022 03:43:20 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 33F028008D; Fri, 2 Sep 2022 03:43:20 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 205D7800CC; Fri, 2 Sep 2022 03:43:20 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0016.hostedemail.com [216.40.44.16]) by kanga.kvack.org (Postfix) with ESMTP id 11D7E8008D for ; Fri, 2 Sep 2022 03:43:20 -0400 (EDT) Received: from smtpin25.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay10.hostedemail.com (Postfix) with ESMTP id E39E3C01C1 for ; Fri, 2 Sep 2022 07:43:19 +0000 (UTC) X-FDA: 79866354918.25.1F2EC49 Received: from desiato.infradead.org (desiato.infradead.org [90.155.92.199]) by imf18.hostedemail.com (Postfix) with ESMTP id D4AAC1C004C for ; Fri, 2 Sep 2022 07:43:18 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=desiato.20200630; h=In-Reply-To:Content-Transfer-Encoding: Content-Type:MIME-Version:References:Message-ID:Subject:Cc:To:From:Date: Sender:Reply-To:Content-ID:Content-Description; bh=OTkZ6uS66u1w+Hbm6TtejxpZoX4M4S5NPkBcQcAWCKc=; b=PnZijlpR1pOR1iufsipFUsPYmX wbuCNPHruLPvnd9YD9OGZaAbljCpwQ375yyM4LxLPNodHP7yyl8nCBECEYTFiQVqc4YVxSJ/V2dlh O/8jbSYyMnq7pIMy+I3eQIfZaErVmTLPipUltIDJnf+p51iDa+Z64wSxdGbbuLpDZVmryFk/FF5GN cP5Tu6T2zNfa688WKGMlX+v33GIJwYaMwjVzwszIeAy17yanlRL0xUsMQD41ZBgPm/IX3evr0bd8h t52Sf3vBachUsH2aTamhLXAmPGIVVmxbsmm6eJm2OoDfb4u1z/Ab3fdh7EznyK7iKAahKesRs1Ztw 16OOfd2w==; Received: from j130084.upc-j.chello.nl ([24.132.130.84] helo=noisy.programming.kicks-ass.net) by desiato.infradead.org with esmtpsa (Exim 4.94.2 #2 (Red Hat Linux)) id 1oU1KH-008c53-Ly; Fri, 02 Sep 2022 07:42:55 +0000 Received: from hirez.programming.kicks-ass.net (hirez.programming.kicks-ass.net [192.168.1.225]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (Client did not present a certificate) by noisy.programming.kicks-ass.net (Postfix) with ESMTPS id 9BFA230010B; Fri, 2 Sep 2022 09:42:51 +0200 (CEST) Received: by hirez.programming.kicks-ass.net (Postfix, from userid 1000) id 793AE2B89F172; Fri, 2 Sep 2022 09:42:51 +0200 (CEST) Date: Fri, 2 Sep 2022 09:42:51 +0200 From: Peter Zijlstra To: Suren Baghdasaryan Cc: akpm@linux-foundation.org, michel@lespinasse.org, jglisse@google.com, mhocko@suse.com, vbabka@suse.cz, hannes@cmpxchg.org, mgorman@suse.de, dave@stgolabs.net, willy@infradead.org, liam.howlett@oracle.com, ldufour@linux.ibm.com, laurent.dufour@fr.ibm.com, paulmck@kernel.org, luto@kernel.org, songliubraving@fb.com, peterx@redhat.com, david@redhat.com, dhowells@redhat.com, hughd@google.com, bigeasy@linutronix.de, kent.overstreet@linux.dev, rientjes@google.com, axelrasmussen@google.com, joelaf@google.com, minchan@google.com, kernel-team@android.com, linux-mm@kvack.org, linux-arm-kernel@lists.infradead.org, linuxppc-dev@lists.ozlabs.org, x86@kernel.org, linux-kernel@vger.kernel.org Subject: Re: [RFC PATCH RESEND 00/28] per-VMA locks proposal Message-ID: References: <20220901173516.702122-1-surenb@google.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20220901173516.702122-1-surenb@google.com> ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1662104599; a=rsa-sha256; cv=none; b=io/XPZ5n+GlMPX9k1W1zHuEoKoNXp6ghkQsOar67DvHYUPbDxTo+XR9DfHpuTidWII8r6a 7dSJSj5IPO2NCyCdC1TO9olzPUvRQPfO0dFEHSGz41ar6tkhPsSsFfJKDoq/g22XC6nNRD cKR0fVWFhVkrY0YHm9+MjDh+8U4mWrw= ARC-Authentication-Results: i=1; imf18.hostedemail.com; dkim=pass header.d=infradead.org header.s=desiato.20200630 header.b=PnZijlpR; spf=none (imf18.hostedemail.com: domain of peterz@infradead.org has no SPF policy when checking 90.155.92.199) smtp.mailfrom=peterz@infradead.org; dmarc=none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1662104599; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:dkim-signature; bh=OTkZ6uS66u1w+Hbm6TtejxpZoX4M4S5NPkBcQcAWCKc=; b=iJaI0b3dn1WCw1+n+/dO74Fl1MBcoHYhmSjC00J+YOK85+u9YQ8W2G2mMReNH1ccAhtjzs tFRmfOHbaxNtBYV739qEpQmmpac1BSSgsRaCjBw8q5QqGrxQqTmT4RE6S0/suxVE2O22j4 ydiJ5QEdox/lRcCQeK/YknXG9dEVxa8= X-Rspam-User: X-Stat-Signature: cetmwms4dfqemdutcmabemah7qstgfcu X-Rspamd-Queue-Id: D4AAC1C004C X-Rspamd-Server: rspam06 Authentication-Results: imf18.hostedemail.com; dkim=pass header.d=infradead.org header.s=desiato.20200630 header.b=PnZijlpR; spf=none (imf18.hostedemail.com: domain of peterz@infradead.org has no SPF policy when checking 90.155.92.199) smtp.mailfrom=peterz@infradead.org; dmarc=none X-HE-Tag: 1662104598-236407 X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: On Thu, Sep 01, 2022 at 10:34:48AM -0700, Suren Baghdasaryan wrote: > This is a proof of concept for per-vma locks idea that was discussed > during SPF [1] discussion at LSF/MM this year [2], which concluded with > suggestion that “a reader/writer semaphore could be put into the VMA > itself; that would have the effect of using the VMA as a sort of range > lock. There would still be contention at the VMA level, but it would be an > improvement.” This patchset implements this suggested approach. The whole reason I started the SPF thing waay back when was because one of the primary reporters at the time had very large VMAs and a per-vma lock wouldn't actually help anything at all. IIRC it was either scientific code initializing a huge matrix or a database with a giant table; I'm sure the archives have better memory than me.