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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 9FA38C433EF for ; Sun, 22 May 2022 15:20:38 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1347828AbiEVPUf (ORCPT ); Sun, 22 May 2022 11:20:35 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:41664 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230290AbiEVPUd (ORCPT ); Sun, 22 May 2022 11:20:33 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 214EA13F09 for ; Sun, 22 May 2022 08:20:33 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id B1D5260FDE for ; Sun, 22 May 2022 15:20:32 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 2A365C385AA; Sun, 22 May 2022 15:20:30 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1653232832; bh=SWE2SZXviYHJb3fNQDeOWauK0tH4udqCDq6KTNopSuk=; h=In-Reply-To:References:Date:From:To:Cc:Subject:From; b=u0EraHkQKmwe76AVYlZ0QfFV8bz81Y0Xn88jmW9xTwq/MYOIr8yX8GccCYsqSNaGw pwASnPM2tFRwqDKACDXopjG4S2P61OGaygxKZJlYudBYbKfZA0ih7OyrkI+S8LrPEJ 596u00mcHY/sK6Ohk63lJBz9uJ39Tfv4sAZFrnvL/zQirpDn9t8HlUegQFZiShbKbh U3T7/gXHf+MUt+uJ1FaAOnMdhG5AQznNuWcfRsIe9ImcV9AVkCi6tv2JHtbVkOLN0K WxAuylUp8210t8kldxltmGJMzU7mWepZEwn+0/ndU3Wn68TMJAW3sKlwtd96FvQzqQ yOpunhFwsmqUg== Received: from compute2.internal (compute2.nyi.internal [10.202.2.46]) by mailauth.nyi.internal (Postfix) with ESMTP id F031A27C0054; Sun, 22 May 2022 11:20:28 -0400 (EDT) Received: from imap48 ([10.202.2.98]) by compute2.internal (MEProxy); Sun, 22 May 2022 11:20:29 -0400 X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvfedrieekgdeklecutefuodetggdotefrodftvf curfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfghnecu uegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmdenuc fjughrpefofgggkfgjfhffhffvvefutgfgsehtqhertderreejnecuhfhrohhmpedftehn ugihucfnuhhtohhmihhrshhkihdfuceolhhuthhosehkvghrnhgvlhdrohhrgheqnecugg ftrfgrthhtvghrnhepudevffdvgedvfefhgeejjeelgfdtffeukedugfekuddvtedvudei leeugfejgefgnecuvehluhhsthgvrhfuihiivgeptdenucfrrghrrghmpehmrghilhhfrh homheprghnugihodhmvghsmhhtphgruhhthhhpvghrshhonhgrlhhithihqdduudeiudek heeifedvqddvieefudeiiedtkedqlhhuthhopeepkhgvrhhnvghlrdhorhhgsehlihhnuh igrdhluhhtohdruhhs X-ME-Proxy: Feedback-ID: ieff94742:Fastmail Received: by mailuser.nyi.internal (Postfix, from userid 501) id BE05431A005D; Sun, 22 May 2022 11:20:26 -0400 (EDT) X-Mailer: MessagingEngine.com Webmail Interface User-Agent: Cyrus-JMAP/3.7.0-alpha0-591-gfe6c3a2700-fm-20220427.001-gfe6c3a27 Mime-Version: 1.0 Message-Id: In-Reply-To: References: <20220519183127.3909598-1-shiyn.lin@gmail.com> <64d0da08-6ffd-4bce-bc66-5097913937b4@kernel.org> Date: Sun, 22 May 2022 08:20:05 -0700 From: "Andy Lutomirski" To: "Matthew Wilcox (Oracle)" Cc: "David Hildenbrand" , "Chih-En Lin" , "Andrew Morton" , linux-mm@kvack.org, "Ingo Molnar" , "Peter Zijlstra (Intel)" , "Juri Lelli" , "Vincent Guittot" , "Dietmar Eggemann" , "Steven Rostedt" , "Ben Segall" , "Mel Gorman" , "Daniel Bristot de Oliveira" , "Christian Brauner" , "Vlastimil Babka" , "William Kucharski" , "John Hubbard" , "Yunsheng Lin" , "Arnd Bergmann" , "Suren Baghdasaryan" , "Colin Cross" , "Feng Tang" , "Eric W. Biederman" , "Mike Rapoport" , "Geert Uytterhoeven" , "Anshuman Khandual" , "Aneesh Kumar K.V" , "Daniel Axtens" , "Jonathan Marek" , "Christophe Leroy" , "Pasha Tatashin" , "Peter Xu" , "Andrea Arcangeli" , "Thomas Gleixner" , "Sebastian Andrzej Siewior" , "Fenghua Yu" , "Linux Kernel Mailing List" , "Kaiyang Zhao" , "Huichun Feng" , "Jim Huang" Subject: Re: [RFC PATCH 0/6] Introduce Copy-On-Write to Page Table Content-Type: text/plain;charset=utf-8 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sat, May 21, 2022, at 5:31 PM, Matthew Wilcox wrote: > On Sat, May 21, 2022 at 03:19:24PM -0700, Andy Lutomirski wrote: >> I can see a rather different use for this type of shared-pagetable >> technology, though: monstrous MAP_SHARED mappings. For database and = some VM >> users, multiple processes will map the same file. If there was a way= to >> ensure appropriate alignment (or at least encourage it) and a way to = handle >> mappings that don't cover the whole file, then having multiple mappin= gs >> share the same page tables could be a decent efficiently gain. This = doesn't >> even need COW -- it's "just" pagetable sharing. > > The mshare proposal did not get a warm reception at LSFMM ;-( > > The conceptual model doesn't seem to work for the MM developers who we= re > in the room. "Fear" was the most-used word. Not sure how we're going > to get to a model of sharing page tables that doesn't scare people. FWIW, I didn=E2=80=99t like mshare. mshare was weird: it seemed to have= one mm own some page tables and other mms share them. I=E2=80=99m talk= ing about having a *file* own page tables and mms map them. This seems = less fear-inducing to me. Circular dependencies are impossible, mmap ca= lls don=E2=80=99t need to propagate, etc. It would still be quite a change, though.