Received: by 2002:a05:6a10:17d3:0:0:0:0 with SMTP id hz19csp3403003pxb; Wed, 14 Apr 2021 04:57:30 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyCrH8MEYoXOx/cwOz6pDylOV5wX/bo8/gs/pBUwxkzkRR8OgkuHXNhEOcEiNIdcfLG7pE0 X-Received: by 2002:a62:1d56:0:b029:249:88fd:bf96 with SMTP id d83-20020a621d560000b029024988fdbf96mr20124014pfd.78.1618401450144; Wed, 14 Apr 2021 04:57:30 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1618401450; cv=none; d=google.com; s=arc-20160816; b=m3tfQXK3W3+F5x+2Y/Ku7phlQpY6I++pgRsPvpQobgN5clz85fWmIK+IrYoFAIvTYJ Nxr8c4fsFYRQA6+CEHZ8mBmP4fBhsuMMroM0b3lFoE75BZ+hKrAqeovio7UEkvAeJTbg 3grG9x30deOCIcVJFzMtEqUvUoZOdtlHi9jsjiPoNBIRaqKyeZF9VdmBUnnDVf8nc8Av B66u8gsbwQzy4gmO+8D9Um/Da2Xt4G64e2epk1XnHkMdqGHMotMWaRCWirocgTUiOZ25 yOtrFx6EQY43nRGCkXNlDcxqFRm3lBShpX6gMRjTPwcKgUF1sB/9NZtfHzGdJQSzAphN Dqtg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:user-agent:references :in-reply-to:date:cc:to:from:subject:message-id; bh=G9mM/aBcfEtqpsmMWHhX1m16fX/u6jdFhXB7FzEu1yU=; b=L/BQykkP9hCdJhf+R0Dq6rpL6uKnY7kfWTMnTWPg/CkbHgKxVMTr1rSlojcx5Hocwl j6X9w51i6D/tZl8OL8Vf7g96lo0JWd5Vkdl5yF9o2MEDiFunSQblpPBeJRtswRVcM02p KLeL3oRdh9dzSHm+KD0ccs9bqmQ7HF7JI3LgKH/CM4OhOk0S1wOjIB9zINckIxmHIaFv b+el7A/4gJh8oSxQppC4DGDO9hWM1cCGEmGVEPOVpD0piFVx3gk6gNtAHUcRJcEoGvZb t1XnrajUg4NJSnxpX9tUNV8rewIoVB/1eGlRKgRFI+zDGoahIKWm6jy1N5aliKwOYEWT kJVg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id i21si21921903pgl.482.2021.04.14.04.57.16; Wed, 14 Apr 2021 04:57:29 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S237066AbhDNCal (ORCPT + 99 others); Tue, 13 Apr 2021 22:30:41 -0400 Received: from shelob.surriel.com ([96.67.55.147]:53626 "EHLO shelob.surriel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232708AbhDNCai (ORCPT ); Tue, 13 Apr 2021 22:30:38 -0400 Received: from imladris.surriel.com ([96.67.55.152]) by shelob.surriel.com with esmtpsa (TLS1.2) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94) (envelope-from ) id 1lWVHk-0002fD-KE; Tue, 13 Apr 2021 22:29:44 -0400 Message-ID: Subject: Re: [PATCH v2 00/16] Multigenerational LRU Framework From: Rik van Riel To: Dave Chinner , Jens Axboe Cc: SeongJae Park , Yu Zhao , linux-mm@kvack.org, Andi Kleen , Andrew Morton , Benjamin Manes , Dave Hansen , Hillf Danton , Johannes Weiner , Jonathan Corbet , Joonsoo Kim , Matthew Wilcox , Mel Gorman , Miaohe Lin , Michael Larabel , Michal Hocko , Michel Lespinasse , Roman Gushchin , Rong Chen , SeongJae Park , Tim Chen , Vlastimil Babka , Yang Shi , Ying Huang , Zi Yan , linux-kernel@vger.kernel.org, lkp@lists.01.org, page-reclaim@google.com Date: Tue, 13 Apr 2021 22:29:44 -0400 In-Reply-To: <20210413231436.GF63242@dread.disaster.area> References: <20210413075155.32652-1-sjpark@amazon.de> <3ddd4f8a-8e51-662b-df11-a63a0e75b2bc@kernel.dk> <20210413231436.GF63242@dread.disaster.area> Content-Type: multipart/signed; micalg="pgp-sha256"; protocol="application/pgp-signature"; boundary="=-F++cZhSa2Af2JhhC9Dpg" User-Agent: Evolution 3.34.4 (3.34.4-1.fc31) MIME-Version: 1.0 Sender: riel@shelob.surriel.com Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --=-F++cZhSa2Af2JhhC9Dpg Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Wed, 2021-04-14 at 09:14 +1000, Dave Chinner wrote: > On Tue, Apr 13, 2021 at 10:13:24AM -0600, Jens Axboe wrote: >=20 > > The initial posting of this patchset did no better, in fact it did > > a bit > > worse. Performance dropped to the same levels and kswapd was using > > as > > much CPU as before, but on top of that we also got excessive > > swapping. > > Not at a high rate, but 5-10MB/sec continually. > >=20 > > I had some back and forths with Yu Zhao and tested a few new > > revisions, > > and the current series does much better in this regard. Performance > > still dips a bit when page cache fills, but not nearly as much, and > > kswapd is using less CPU than before. >=20 > Profiles would be interesting, because it sounds to me like reclaim > *might* be batching page cache removal better (e.g. fewer, larger > batches) and so spending less time contending on the mapping tree > lock... >=20 > IOWs, I suspect this result might actually be a result of less lock > contention due to a change in batch processing characteristics of > the new algorithm rather than it being a "better" algorithm... That seems quite likely to me, given the issues we have had with virtual scan reclaim algorithms in the past. SeongJae, what is this algorithm supposed to do when faced with situations like this: 1) Running on a system with 8 NUMA nodes, and memory pressure in one of those nodes. 2) Running PostgresQL or Oracle, with hundreds of processes mapping the same (very large) shared memory segment. How do you keep your algorithm from falling into the worst case virtual scanning scenarios that were crippling the 2.4 kernel 15+ years ago on systems with just a few GB of memory? --=20 All Rights Reversed. --=-F++cZhSa2Af2JhhC9Dpg Content-Type: application/pgp-signature; name="signature.asc" Content-Description: This is a digitally signed message part Content-Transfer-Encoding: 7bit -----BEGIN PGP SIGNATURE----- iQEzBAABCAAdFiEEKR73pCCtJ5Xj3yADznnekoTE3oMFAmB2U5gACgkQznnekoTE 3oPxNggArWAg3BKjFNFCqV6hmRJcPb8OiTUU7M6upcMdSo+qTt5ivPbR1oqnHCc4 9B41LFwOhK4jc2LThte6bsSVL3GkPTia9RC5oXouoUiwJdp56vhc6fFnWcXqjJTJ M2E8mu4iJKq7nDGYqz/w212PB93qDfyv00newmUFybKj6VaJoJf2iR7WLjpU4wjK SNXJct21QO7AftDHPGYsXmSqVK4vQrodF0b9Pl5CVvfida/SJk0da762a9R8KwqF pIBWVmGNBD7pZWp7xwvYff0OnIt/5n43O2ZdOhKOwRa6H2jEdaAB3IvsQSknBTJF FO+6mbmBscAP3jwlbHf2DddcgZKh5A== =0Yad -----END PGP SIGNATURE----- --=-F++cZhSa2Af2JhhC9Dpg--