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 X-Spam-Level: X-Spam-Status: No, score=-2.7 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 0E002C433F5 for ; Fri, 3 Sep 2021 23:42:10 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id 7E67060C51 for ; Fri, 3 Sep 2021 23:42:09 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org 7E67060C51 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=gmail.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=kvack.org Received: by kanga.kvack.org (Postfix) id E5AF56B0071; Fri, 3 Sep 2021 19:42:08 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id E0A546B0072; Fri, 3 Sep 2021 19:42:08 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id CFA32900002; Fri, 3 Sep 2021 19:42:08 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0221.hostedemail.com [216.40.44.221]) by kanga.kvack.org (Postfix) with ESMTP id C155F6B0071 for ; Fri, 3 Sep 2021 19:42:08 -0400 (EDT) Received: from smtpin06.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay01.hostedemail.com (Postfix) with ESMTP id 785B618549E1B for ; Fri, 3 Sep 2021 23:42:08 +0000 (UTC) X-FDA: 78547887936.06.BD39B38 Received: from mail-pg1-f178.google.com (mail-pg1-f178.google.com [209.85.215.178]) by imf19.hostedemail.com (Postfix) with ESMTP id 4335BB00009D for ; Fri, 3 Sep 2021 23:42:08 +0000 (UTC) Received: by mail-pg1-f178.google.com with SMTP id w7so546106pgk.13 for ; Fri, 03 Sep 2021 16:42:08 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=date:from:subject:to:cc:references:in-reply-to:mime-version :message-id:content-transfer-encoding; bh=RbmyCxovg1DLvfcJ/FSqFRVxSV6Zui9nsoD/b3owWjc=; b=gp3HM/UaZFcDgZFLttHcNoTPJ8WQGsp0TqMxEXvTviJj+kLkfmazp0t9rSp/tlfBil LilpCq5EfyguTDLk9drAXfb0Ii+8McxJJMyaE+vrk/0V6w0OP3+pri3WKvXGYdj8eBIg t/sCaCKq30+Pje1Pv0Gu/pQQXmkiwkq2+UggEfVKhHHPbYAZIXb6Ug69fzrGoHnW28WD Qx81fh8ArLnKNw8Q9oZRLmjAPGOFGvN8TLvz8HzMp+VQa3bzEFaEwTzU7/xeuRFtPv9h EEbJ0lqV5sWdb/rTkUqOnkpngiPpcCQ7ZmBVJ4UIp/B0t+n0TABSNlY+2+N8mUXAG2Ni O7pw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:subject:to:cc:references:in-reply-to :mime-version:message-id:content-transfer-encoding; bh=RbmyCxovg1DLvfcJ/FSqFRVxSV6Zui9nsoD/b3owWjc=; b=hnX1jwL93O9SjfGkLge3khO2nrOu0aTgKCRgjR7lDT8345iSp0tr7k6gGJuztKiGu9 MWZ4k7N2/lbV+HHdJVCXWKp9k4sggDF93pReKIWmUHYSZfGxB5osYf02x9Lt0QB5JKPB jN7ub3sGxEHz7TjVt81mlylfD+pTo9KLRfvvrW8qcZ7YeQWrLXUh3wOsBTJH/bMpjtKf m+cjW8iNR0egFcY2Q5XTIjCqtw9FzkY5lAMsY0qDPSrE1qR1bH4zLSzeacQT1Z5RFNuC unr1Zt5FbK2lKoqDSO6kVv2oMwtscv2zYEeycrxyehvpYWdcKn6iuBP+/tnUFd54y6OB mNNQ== X-Gm-Message-State: AOAM531zaWibFbaPM9XafA2gqANgCNwjlt4bm8Xhm8pasPmA2pL7eoAR Fe17OPv9+tYv3bOxSqUkNQ8= X-Google-Smtp-Source: ABdhPJwzvFqJO1HdxqofZWVyERIxJIv9nnL9AKDMjxH9L00pSAPQxNgPM5a4wmxZRjze/AeIO+UAFg== X-Received: by 2002:a63:6dc6:: with SMTP id i189mr1267977pgc.458.1630712527245; Fri, 03 Sep 2021 16:42:07 -0700 (PDT) Received: from localhost (203-219-56-12.tpgi.com.au. [203.219.56.12]) by smtp.gmail.com with ESMTPSA id x189sm421549pfx.30.2021.09.03.16.42.05 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 03 Sep 2021 16:42:06 -0700 (PDT) Date: Sat, 04 Sep 2021 09:42:00 +1000 From: Nicholas Piggin Subject: Re: Is it possible to implement the per-node page cache for programs/libraries? To: Matthew Wilcox Cc: akpm@linux-foundation.org, linux-kernel@vger.kernel.org, linux-mm@kvack.org, Shijie Huang , song.bao.hua@hisilicon.com, torvalds@linux-foundation.org, viro@zeniv.linux.org.uk, Frank Wang References: <1630552995.2mupnzoqzs.astroid@bobo.none> <1630652670.aplcvu6g23.astroid@bobo.none> In-Reply-To: MIME-Version: 1.0 Message-Id: <1630712371.zxj5zdhheu.astroid@bobo.none> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Authentication-Results: imf19.hostedemail.com; dkim=pass header.d=gmail.com header.s=20210112 header.b="gp3HM/Ua"; spf=pass (imf19.hostedemail.com: domain of npiggin@gmail.com designates 209.85.215.178 as permitted sender) smtp.mailfrom=npiggin@gmail.com; dmarc=pass (policy=none) header.from=gmail.com X-Stat-Signature: 948gkcckytbq616bexoc9f9wxmj18dx9 X-Rspamd-Queue-Id: 4335BB00009D X-Rspamd-Server: rspam04 X-HE-Tag: 1630712528-829217 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: Excerpts from Matthew Wilcox's message of September 4, 2021 5:01 am: > On Fri, Sep 03, 2021 at 05:10:31PM +1000, Nicholas Piggin wrote: >> Excerpts from Matthew Wilcox's message of September 2, 2021 8:17 pm: >> > On Thu, Sep 02, 2021 at 01:25:36PM +1000, Nicholas Piggin wrote: >> >> > I have been thinking about this a bit; one of our internal performa= nce >> >> > teams flagged the potential performance win to me a few months ago. >> >> > I don't have a concrete design for text replication yet; there have= been >> >> > various attempts over the years, but none were particularly compell= ing. >> >>=20 >> >> What was not compelling about it? >> >=20 >> > It wasn't merged, so clearly it wasn't compelling enough? >>=20 >> Ha ha. It sounded like you had some reasons you didn't find it=20 >> particularly compelling :P >=20 > I haven't studied it in detail, but it seems to me that your patch (from > 2007!) chooses whether to store pages or pcache_desc pointers in i_pages. > Was there a reason you chose to do it that way instead of having per-node > i_mapping pointers? What Linus said. The patch was obviously mechanism only and more=20 heuristics would need to be done (in that case you could have per inode=20 hints or whatever). > (And which way would you choose to do it now, given > the infrastructure we have now?) I'm not aware of anything new that would change it fundamentally. Thanks, Nick