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=-5.8 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,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 E39F7C07E95 for ; Tue, 20 Jul 2021 17:21:22 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id BFC2C610D2 for ; Tue, 20 Jul 2021 17:21:22 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233785AbhGTQj3 (ORCPT ); Tue, 20 Jul 2021 12:39:29 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:52876 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230474AbhGTQiJ (ORCPT ); Tue, 20 Jul 2021 12:38:09 -0400 Received: from casper.infradead.org (casper.infradead.org [IPv6:2001:8b0:10b:1236::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E339BC061574; Tue, 20 Jul 2021 10:18:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=casper.20170209; h=In-Reply-To:Content-Type:MIME-Version: References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=nIUPbWmLSj16v4fdAmjxUh4nxogfx1bpU0hHVWTHTvI=; b=nAMqbSKWqbj/Ac8oc6FDFmgton RWU7nDnH8HrY85pFnG7w+Znd8kqgpgYH6kGrc0ZS0U4Rj3cgtOVkZ9CQVcSB3AvQJmFeaBpDg+AHQ 3h17EK9hTAwPtE9UQjVBjT9mYQ+kKPofbajFnmisOvdG3HmquACGcZSlEszqrCdkAGjDlyt+lkrQI LluCGBk2OL/UMvMOhPbeJDLHHibCxk6RvoNSe81nNjIfrVuvZizcHHWE5F9fKbAYiLEXwW3tPSiYx WWVglYjmfJGXd1ANfpypqnnW2wcjiJp4xM99heruNQkZJtVfWHzadyV2PUALLWwC3WAXgisP+MSTT i9ru9xuA==; Received: from willy by casper.infradead.org with local (Exim 4.94.2 #2 (Red Hat Linux)) id 1m5tNl-008LUQ-99; Tue, 20 Jul 2021 17:18:17 +0000 Date: Tue, 20 Jul 2021 18:18:13 +0100 From: Matthew Wilcox To: Mike Rapoport Cc: linux-kernel@vger.kernel.org, linux-mm@kvack.org, linux-fsdevel@vger.kernel.org Subject: Re: [PATCH v14 000/138] Memory folios Message-ID: References: <20210715033704.692967-1-willy@infradead.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Jul 20, 2021 at 06:35:50PM +0300, Mike Rapoport wrote: > On Tue, Jul 20, 2021 at 04:23:29PM +0100, Matthew Wilcox wrote: > > Which patch did you go up to for that? If you're going past patch 50 or > > so, then you're starting to add functionality (ie support for arbitrary > > order pages), so a certain amount of extra code size might be expected. > > I measured 6KB at patch 32 or so, then between patch 32 & 50 was pretty > > much a wash. > > I've used folio_14 tag: > > commit 480552d0322d855d146c0fa6fdf1e89ca8569037 (HEAD, tag: folio_14) > Author: Matthew Wilcox (Oracle) > Date: Wed Feb 5 11:27:01 2020 -0500 > > mm/readahead: Add multi-page folio readahead Probably worth trying the for-next tag instead to get a meaningful comparison of how much using folios saves over pages. I don't want to give the impression that this is all that can be saved by switching to folios. There are still hundreds of places that call PageFoo(), SetPageFoo(), ClearPageFoo(), put_page(), get_page(), lock_page() and so on. There's probably another 20KB of code that can be removed that way.