Received: by 2002:a05:6a10:7420:0:0:0:0 with SMTP id hk32csp72382pxb; Wed, 16 Feb 2022 22:09:41 -0800 (PST) X-Google-Smtp-Source: ABdhPJxfx0ZswrrPor93S7hgn9C1P4V8cpi1mfyackZJTlDXzpK3QdZUfnL8Od8JB/bInrjn/GCI X-Received: by 2002:a17:906:3650:b0:6ce:a6e0:3e97 with SMTP id r16-20020a170906365000b006cea6e03e97mr1151862ejb.15.1645078180810; Wed, 16 Feb 2022 22:09:40 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1645078180; cv=none; d=google.com; s=arc-20160816; b=T75USGlWkFetaSdGeqKo/2wT7tQd54HaRTC2go8jjZd66RgdrHntuaIVv8VnFrcCr0 UUF/E5ppYkHSB8JqqMu/ZUvaSSf+DLYtzhyUMzp7uE4pnOMne1YWm7Oonfayye3M1A+B AWgw+/VwIAJvbR0JY8aM5Sq5OkviJK5XsuW/X1IggeS31JVYLQn72ru64/LwNNN+6ags 3y0NLG4P4t9+TkNXCweOYrM5Fmpy9zEzNqbk08LBXS/oPa3uMf7wA5ePs5KaY+gZhwPY A1Bs3vhbJQ1MyNrCyYvDd+iCLiYSYYtLk8RrB+95eqLNVJP1qhkPVKWwBW3lvVAJTY+l Mpog== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from; bh=7v+G5S0XIclaSEb/uTiOf3t3Fvwy/fJAii07fcJRSZM=; b=Mhbg+Z4g3gp8HW6UNwnJgQYRlkZB6rGlKC9M+7wVanqnzpIEwhZC6LZzpP0isbkzGo GvLwt77RxNIPsthymnlI7X0Kpfh4c929ipykduMNQPJPWAp7jam7dbDQnfITt9VYDBJz wLwml/p+90dh3IbdZjQPgl4jhQpGBZFRImdUyQwflSXnfThn1OY/fZOR2XRvWeHrh/x6 WIpI6a7HqdB9tVc8jrnPl/iH0e02ckH0Rn+x+zdcFFyt6JiFjkp0CpuyFFPK55Ici0Ra DBbBLymbVnXY2/dauGPQB0piGj+nR9Gc08sZRIZyV/WEZYUzBsOeU2ad40sdqbUNLwH+ 4qVQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id e19si1038617edz.111.2022.02.16.22.09.17; Wed, 16 Feb 2022 22:09:40 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S238687AbiBQAWz (ORCPT + 99 others); Wed, 16 Feb 2022 19:22:55 -0500 Received: from mxb-00190b01.gslb.pphosted.com ([23.128.96.19]:35134 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S238681AbiBQAWy (ORCPT ); Wed, 16 Feb 2022 19:22:54 -0500 Received: from outbound-smtp26.blacknight.com (outbound-smtp26.blacknight.com [81.17.249.194]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1FBC1137744 for ; Wed, 16 Feb 2022 16:22:39 -0800 (PST) Received: from mail.blacknight.com (pemlinmail05.blacknight.ie [81.17.254.26]) by outbound-smtp26.blacknight.com (Postfix) with ESMTPS id 878D0CAD5D for ; Thu, 17 Feb 2022 00:22:38 +0000 (GMT) Received: (qmail 22298 invoked from network); 17 Feb 2022 00:22:38 -0000 Received: from unknown (HELO stampy.112glenside.lan) (mgorman@techsingularity.net@[84.203.17.223]) by 81.17.254.9 with ESMTPA; 17 Feb 2022 00:22:38 -0000 From: Mel Gorman To: Andrew Morton Cc: Aaron Lu , Dave Hansen , Vlastimil Babka , Michal Hocko , Jesper Dangaard Brouer , LKML , Linux-MM , Mel Gorman Subject: [PATCH v2 0/6] Follow-up on high-order PCP caching Date: Thu, 17 Feb 2022 00:22:21 +0000 Message-Id: <20220217002227.5739-1-mgorman@techsingularity.net> X-Mailer: git-send-email 2.31.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,SPF_HELO_NONE, SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org This series replaces v1 of the "Follow-up on high-order PCP caching" series in mmots. Changelog since v1 o Drain the requested PCP list first (vbabka) o Use [min|max]_pindex properly to reduce search depth (vbabka) o Update benchmark results in changelogs Commit 44042b449872 ("mm/page_alloc: allow high-order pages to be stored on the per-cpu lists") was primarily aimed at reducing the cost of SLUB cache refills of high-order pages in two ways. Firstly, zone lock acquisitions was reduced and secondly, there were fewer buddy list modifications. This is a follow-up series fixing some issues that became apparant after merging. Patch 1 is a functional fix. It's harmless but inefficient. Patches 2-5 reduce the overhead of bulk freeing of PCP pages. While the overhead is small, it's cumulative and noticable when truncating large files. The changelog for patch 4 includes results of a microbench that deletes large sparse files with data in page cache. Sparse files were used to eliminate filesystem overhead. Patch 6 addresses issues with high-order PCP pages being stored on PCP lists for too long. Pages freed on a CPU potentially may not be quickly reused and in some cases this can increase cache miss rates. Details are included in the changelog. mm/page_alloc.c | 135 +++++++++++++++++++++++++----------------------- 1 file changed, 69 insertions(+), 66 deletions(-) -- 2.31.1