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=-17.5 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=unavailable 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 004CEC07E95 for ; Tue, 20 Jul 2021 10:44:24 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id DB2E76120A for ; Tue, 20 Jul 2021 10:44:23 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234715AbhGTKDG (ORCPT ); Tue, 20 Jul 2021 06:03:06 -0400 Received: from mail.kernel.org ([198.145.29.99]:33750 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S237524AbhGTKAy (ORCPT ); Tue, 20 Jul 2021 06:00:54 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id 2A58161165; Tue, 20 Jul 2021 10:41:24 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1626777688; bh=yEsKWSjIDeG5CYGsxYSfoyolXUgGMddSmWQesyZ8Rmw=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=YjTzdqh+lFCzldzGa4JyDiq3MKIfE4yqdhh1SblhWV2Al1xZT8cr6K+caVmTgBMWE knSC7+kc1UPon9e25FX4yL9H6uNmm4hiBbhyEGlBoVE8VUl9hOZxjPpE+QK6HDMO5M bJq+JDUzajyHyV0T4gho2RsuEm6VfQztUZmeX5ihQHk0HzXqbNkJhZ9HYKAdhKN63u FJM3kAX4whqBLcZKjwh29crwhenYPzrmZliew5hJjcaRF0j9uXkE9L/7l+MYSQd2m0 uJBxi4o59Ay5j5rNJi2wGBjMi4bh5CxFKJmpB/6pSTowZ92O5wa7jJgf+avOH+z2A2 ldPpJ77IUcrqg== Date: Tue, 20 Jul 2021 13:41:20 +0300 From: Mike Rapoport To: "Matthew Wilcox (Oracle)" Cc: linux-kernel@vger.kernel.org, linux-mm@kvack.org, linux-fsdevel@vger.kernel.org, Zi Yan , Christoph Hellwig , Jeff Layton , "Kirill A . Shutemov" , Vlastimil Babka , William Kucharski , David Howells Subject: Re: [PATCH v14 007/138] mm: Add folio_put() Message-ID: References: <20210715033704.692967-1-willy@infradead.org> <20210715033704.692967-8-willy@infradead.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20210715033704.692967-8-willy@infradead.org> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Jul 15, 2021 at 04:34:53AM +0100, Matthew Wilcox (Oracle) wrote: > If we know we have a folio, we can call folio_put() instead of put_page() > and save the overhead of calling compound_head(). Also skips the > devmap checks. > > This commit looks like it should be a no-op, but actually saves 684 bytes > of text with the distro-derived config that I'm testing. Some functions > grow a little while others shrink. I presume the compiler is making > different inlining decisions. > > Signed-off-by: Matthew Wilcox (Oracle) > Reviewed-by: Zi Yan > Reviewed-by: Christoph Hellwig > Acked-by: Jeff Layton > Acked-by: Kirill A. Shutemov > Acked-by: Vlastimil Babka > Reviewed-by: William Kucharski > Reviewed-by: David Howells > --- > include/linux/mm.h | 33 ++++++++++++++++++++++++++++----- > 1 file changed, 28 insertions(+), 5 deletions(-) Acked-by: Mike Rapoport