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 kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 007CAC433F5 for ; Thu, 17 Feb 2022 00:22:41 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 4FA406B0078; Wed, 16 Feb 2022 19:22:41 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id 4A95D6B007B; Wed, 16 Feb 2022 19:22:41 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 370F46B007D; Wed, 16 Feb 2022 19:22:41 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (relay.hostedemail.com [64.99.140.28]) by kanga.kvack.org (Postfix) with ESMTP id 24D646B0078 for ; Wed, 16 Feb 2022 19:22:41 -0500 (EST) Received: from smtpin04.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay09.hostedemail.com (Postfix) with ESMTP id D95D62338E for ; Thu, 17 Feb 2022 00:22:40 +0000 (UTC) X-FDA: 79150370880.04.876913D Received: from outbound-smtp06.blacknight.com (outbound-smtp06.blacknight.com [81.17.249.39]) by imf16.hostedemail.com (Postfix) with ESMTP id E58CD180003 for ; Thu, 17 Feb 2022 00:22:39 +0000 (UTC) Received: from mail.blacknight.com (pemlinmail05.blacknight.ie [81.17.254.26]) by outbound-smtp06.blacknight.com (Postfix) with ESMTPS id 87AD8C2B84 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-Rspam-User: X-Rspamd-Server: rspam04 X-Rspamd-Queue-Id: E58CD180003 X-Stat-Signature: sqpssixnqjm3sebtwdox8wshqp5tm5cz Authentication-Results: imf16.hostedemail.com; dkim=none; dmarc=none; spf=pass (imf16.hostedemail.com: domain of mgorman@techsingularity.net designates 81.17.249.39 as permitted sender) smtp.mailfrom=mgorman@techsingularity.net X-HE-Tag: 1645057359-199784 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: 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