Received: by 2002:a05:6a10:a0d1:0:0:0:0 with SMTP id j17csp2410110pxa; Mon, 24 Aug 2020 13:25:39 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyTjZJA+EaAk+s4u7Jajr0Tf0kLr+jOV9zASE7kywykCZulBIR/q92s8qRjD8z93l5Fpad2 X-Received: by 2002:a17:906:57d9:: with SMTP id u25mr6467095ejr.543.1598300738855; Mon, 24 Aug 2020 13:25:38 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1598300738; cv=none; d=google.com; s=arc-20160816; b=F/j4hmoRDBgy3nJJLAEonyDdnRgDzRgnYvFf3FjfI8xUv30/4BLNB1UnqDx9K4YDir MPeocx9z6bWt8D/YYSuMJKdi+w+P0j23YtCwFBHlQGpufrkzvwSs0/WTySiIH5yQEJDd x/OgLLD1DwHiNzaaNFJODj5KUVckQqmbd9AkPgaR9pygMy58XDTD0H5GV6F1jE5GWU2W QGmaCimpa5BaCQgQvCLVxF/rIpDMiI+EsTvft5kp2/akb7qHRg9EhyVDN+6JkWwOFQ4v 6ulZmheGtvYAgXCZC7iBnxIHVhL1aayimzbKdAwoI6VyFSIWv/sMddSGChPaEqPZ6XGB hiJQ== 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 :message-id:in-reply-to:subject:cc:to:from:date:dkim-signature; bh=jZJmpxUuRgi9v+jqMkzrZxBWaBUdOYUK94hlHfWB0r0=; b=n1CRwx5hZJ0l03MKwcQSBWXi9D+DArmsL9yhCwrbD2saH7AP6ONul7SYEGDZwwfy1r tfghO2ZG28QevKzTRpTnEMKdxsBhPuiIAkNZLG0h1sBPbZDknmqN+BnyXyq+aufjwS/P DinGnUF1gOA3DRsdeilMd4GN5Awm/Yoif+zq/xuTiEUajIyKiWDOdhs3RYdoFp1HENEG liYM7U8fP6nnF/4j3UM99MvLoqYZRFbRUe9InSOf1jwQxa8BI/i9RCqLzOoa/7HjcgMR l0IhrPNgrm2l7cwmV0wtZfdyUdUGf4yv/VO30SOLYng68y4E89wpYtwCN4y62sxIVZOp dLTw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b="MR7Bq/ZQ"; 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; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id bc19si7230421edb.237.2020.08.24.13.25.15; Mon, 24 Aug 2020 13:25:38 -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; dkim=pass header.i=@google.com header.s=20161025 header.b="MR7Bq/ZQ"; 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; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726222AbgHXUYk (ORCPT + 99 others); Mon, 24 Aug 2020 16:24:40 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:32916 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725904AbgHXUYk (ORCPT ); Mon, 24 Aug 2020 16:24:40 -0400 Received: from mail-oi1-x242.google.com (mail-oi1-x242.google.com [IPv6:2607:f8b0:4864:20::242]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id AC461C061574 for ; Mon, 24 Aug 2020 13:24:38 -0700 (PDT) Received: by mail-oi1-x242.google.com with SMTP id k4so9520365oik.2 for ; Mon, 24 Aug 2020 13:24:38 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=date:from:to:cc:subject:in-reply-to:message-id:references :user-agent:mime-version; bh=jZJmpxUuRgi9v+jqMkzrZxBWaBUdOYUK94hlHfWB0r0=; b=MR7Bq/ZQYkG+RC4+pV7gn6md1ynlBoEqj97iWI4NmkE5R4tB+vonwjD3hBXKNY5NXi s6RgBUQ6GmZB9oN4eO759+P2STSWXsvR2iTFwi5em6FO1uSp9K6BrqWiBz2kHenZzz1P Py+yCIIKP4LDK18RFOWS5hwNf9QS/atikITGHcNt+QLbnxvvnLbqWHGkYnXujCSOVLTs 81PlBJi5s6WGIJnJ2cHHmh6PUWyvIS66CnqqIjAVzz/+qHPYBCk5bMfIYwxbQwPJZTlO HeP6Hse7VzkhwJXSINHM5U3hSAJUo0uzysf4ar42eBFpZytIQnrqwxAFiM3GD2E23ZeY IOmA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:in-reply-to:message-id :references:user-agent:mime-version; bh=jZJmpxUuRgi9v+jqMkzrZxBWaBUdOYUK94hlHfWB0r0=; b=lZSsnE1YflpkRoL/h/mr98/ap1b5C1Bu9L82qxQWcP+/q1VNDnJdgFiGcRYjSe+fk/ rcwrKIp+ygOP6dzDF3bB8y8I7I20s2rf10iSt6QL5MFQdFvWgXL8M6Y6fMOUuXjTZF33 jCThzrjV3ZvtyrNhRgKqis+bepWU7TaOaZtJ+SowTkpLy7atiTXE7JoPeiPGRd0ro49K EANS6/EpcwP6b7STze1DzNUfwtBI2Q1ozTD637qHMKLMbl37CI2w3XKMhYxsEqI30OXi mKfn8Q0koMQvGfslN92koLfJLjjnZwk8IRPLg8VmDJjwPoeUSfFAP4j8Sznh2/Whntj/ q/Vg== X-Gm-Message-State: AOAM5314BtThKrVamYWS6J0rb725O8TQ/NJ9x3Y1yww/QzxKPhl8Zsn/ zYQGiUGdO5STxKa2NTAmzOJPHg== X-Received: by 2002:aca:670b:: with SMTP id z11mr707247oix.6.1598300677784; Mon, 24 Aug 2020 13:24:37 -0700 (PDT) Received: from eggly.attlocal.net (172-10-233-147.lightspeed.sntcca.sbcglobal.net. [172.10.233.147]) by smtp.gmail.com with ESMTPSA id a15sm2130930oid.49.2020.08.24.13.24.33 (version=TLS1 cipher=ECDHE-ECDSA-AES128-SHA bits=128/128); Mon, 24 Aug 2020 13:24:36 -0700 (PDT) Date: Mon, 24 Aug 2020 13:24:20 -0700 (PDT) From: Hugh Dickins X-X-Sender: hugh@eggly.anvils To: Andrew Morton cc: Alex Shi , mgorman@techsingularity.net, tj@kernel.org, hughd@google.com, khlebnikov@yandex-team.ru, daniel.m.jordan@oracle.com, willy@infradead.org, hannes@cmpxchg.org, lkp@intel.com, linux-mm@kvack.org, linux-kernel@vger.kernel.org, cgroups@vger.kernel.org, shakeelb@google.com, iamjoonsoo.kim@lge.com, richard.weiyang@gmail.com, kirill@shutemov.name, alexander.duyck@gmail.com, rong.a.chen@intel.com, mhocko@suse.com, vdavydov.dev@gmail.com, shy828301@gmail.com Subject: Re: [PATCH v18 00/32] per memcg lru_lock In-Reply-To: <20200824114204.cc796ca182db95809dd70a47@linux-foundation.org> Message-ID: References: <1598273705-69124-1-git-send-email-alex.shi@linux.alibaba.com> <20200824114204.cc796ca182db95809dd70a47@linux-foundation.org> User-Agent: Alpine 2.11 (LSU 23 2013-08-11) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, 24 Aug 2020, Andrew Morton wrote: > On Mon, 24 Aug 2020 20:54:33 +0800 Alex Shi wrote: > > > The new version which bases on v5.9-rc2. Well timed and well based, thank you Alex. Particulary helpful to me, to include those that already went into mmotm: it's a surer foundation to test on top of the -rc2 base. > > the first 6 patches was picked into > > linux-mm, and add patch 25-32 that do some further post optimization. > > 32 patches, version 18. That's quite heroic. I'm unsure whether I > should merge it up at this point - what do people think? I'd love for it to go into mmotm - but not today. Version 17 tested out well. I've only just started testing version 18, but I'm afraid there's been a number of "improvements" in between, which show up as warnings (lots of VM_WARN_ON_ONCE_PAGE(!memcg) - I think one or more of those are already in mmotm and under discussion on the list, but I haven't read through yet, and I may have caught more cases to examine; a per-cpu warning from munlock_vma_page(); something else flitted by at reboot time before I could read it). No crashes so far, but I haven't got very far with it yet. I'll report back later in the week. Andrew demurred on version 17 for lack of review. Alexander Duyck has been doing a lot on that front since then. I have intended to do so, but it's a mirage that moves away from me as I move towards it: I have some time in the coming weeks to get back to that, but it would help me if the series is held more static by being in mmotm - we may need fixes, but improvements are liable to get in the way of finalizing. I still find the reliance on TestClearPageLRU, rather than lru_lock, hard to wrap my head around: but for so long as it's working correctly, please take that as a problem with my head (and something we can certainly change later if necessary, by re-adding the use of lru_lock in certain places (or by fitting me with a new head)). > > > > > Following Daniel Jordan's suggestion, I have run 208 'dd' with on 104 > > containers on a 2s * 26cores * HT box with a modefied case: > > https://git.kernel.org/pub/scm/linux/kernel/git/wfg/vm-scalability.git/tree/case-lru-file-readtwice > > With this patchset, the readtwice performance increased about 80% > > in concurrent containers. > > That's rather a slight amount of performance testing for a huge > performance patchset! Indeed. And I see that clause about readtwice performance increased 80% going back eight months to v6: a lot of fundamental bugs have been fixed in it since then, so I do think it needs refreshing. It could be faster now: v16 or v17 fixed the last bug I knew of, which had been slowing down reclaim considerably. When I last timed my repetitive swapping loads (not loads anyone sensible would be running with), across only two memcgs, Alex's patchset was slightly faster than without: it really did make a difference. But I tend to think that for all patchsets, there exists at least one test that shows it faster, and another that shows it slower. > Is more detailed testing planned? Not by me, performance testing is not something I trust myself with, just get lost in the numbers: Alex, this is what we hoped for months ago, please make a more convincing case, I hope Daniel and others can make more suggestions. But my own evidence suggests it's good. Hugh