Received: by 2002:a05:6a10:f347:0:0:0:0 with SMTP id d7csp2680407pxu; Mon, 7 Dec 2020 12:38:05 -0800 (PST) X-Google-Smtp-Source: ABdhPJxWgNrIyHT1Mf+jeeE7e2SOz9mGxNcOCIod2Xfl4ZoegL5aEtYMursDwwZjZIpwC7wPj+AQ X-Received: by 2002:aa7:c98d:: with SMTP id c13mr22603762edt.188.1607373485794; Mon, 07 Dec 2020 12:38:05 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1607373485; cv=none; d=google.com; s=arc-20160816; b=CSFGxt52LSLdCuZXPWVYp+UVjpMEP8snWocpmaIUiRFJDJpFESSrL0WhkY+xuWuMel juLSaz52ZiRtghp8UGFtNfD9908Di/pPsnhavYoqrpsVtcx+7OtqG/JGb2mkiTWopkzf GzMSZXo/i/UjLACmS9SEm5aAjwc50eJtOXYAyQ/UC1XMyP9IbLeZjadvhuZlXPn996oM AgJZJUwRSlEqYAVLHEi9QBc6wdap3Cq/F0gicMnd4PPc20x3qc2NEPQxKFaN8snPnhvd SfPveyerTdrcMh6FElMyOYNrm8S4o9cLTXTv341tbvxiLZCxacLHeevFdnqE8yn6RLnY K8sw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:user-agent:references:message-id :in-reply-to:subject:cc:to:from:date:dkim-signature; bh=VF+dRBuajSL16Efm+Qk9iftapw2E7SOSirPhcnw+PnQ=; b=HnISxpB0XB5TdHKqjz9/Pb1L+p8Qzd+nB/GoKFkRw/DceK5GsI2PFIw3b6s+EY+sdY mHXazLsCpKHuhcx5HBUts7Z4wV5cxCSaTRUj5kUkXfarv8H0XW3KLzWvg/JXqzC8VjJP f4b+rwwAWomKAwv+IgTeVXww6pLrqgS9/lUPFp5q89kmPl0mKrweXmC/T1Vd4nVtKm0u HbSSZAneVc53g8OnVQrz7T1ChHGh1FBm/gfewNCawlbH8qUQLd1QtTfvljk2BlnENdNz yRxvlM5iH8+vCvVX1QItvmSm9DW/W9+Pgasqmjo+BQ/EcLXEfpXtmhhe6V85/sA8jSMp 6JjQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=ZRA2+e52; 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 dn6si6694654ejc.234.2020.12.07.12.37.42; Mon, 07 Dec 2020 12:38:05 -0800 (PST) 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=ZRA2+e52; 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 S1726149AbgLGUeS (ORCPT + 99 others); Mon, 7 Dec 2020 15:34:18 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40684 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726141AbgLGUeR (ORCPT ); Mon, 7 Dec 2020 15:34:17 -0500 Received: from mail-ot1-x344.google.com (mail-ot1-x344.google.com [IPv6:2607:f8b0:4864:20::344]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 4E5DCC061793 for ; Mon, 7 Dec 2020 12:33:37 -0800 (PST) Received: by mail-ot1-x344.google.com with SMTP id j12so13763969ota.7 for ; Mon, 07 Dec 2020 12:33:37 -0800 (PST) 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=VF+dRBuajSL16Efm+Qk9iftapw2E7SOSirPhcnw+PnQ=; b=ZRA2+e52xlSYiJHPZTaBAxFXuVgSCguGt+17cXdyunFJAuKyaHC0N9M0+4wVV+JNu/ aS6Ru6m3Y+wnCnDvTaR0B9YOhtU4H+7LE/3LGO0G8PmR1IrdqhucfywKGLBMNQLyMXu/ XJSr+UlHYySaZWgshmFkJXhyvI//6ZYqsYHP2wgrjLmT1qlB1JlPb9O13tbr6L0bBWLe GRMCt7godtRnbrHZWJKC5DL6rW4nmuRO1x9OHwbZyq7CAqDi7cjSnTBdGjEjq1IFVhKo fbeRgmd7/Vs61w3QEF43+SBNzMP6YdnFO+5G59r4xPy9OUThCHiccAY3BNCrGBsllVky hvJQ== 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=VF+dRBuajSL16Efm+Qk9iftapw2E7SOSirPhcnw+PnQ=; b=tpvpICwGoQ16SoUO3OUY4Dgisc/0pJBte+sxNPxUyP+OCBP/rJWa+nNQHAoWAMeX6O NNrYPFvAs40WmYj03g9n9TrufJcOGk9PnKmDCPh6wKALc5G/sDvdsSuTWMxVHBzux3B5 wrFzJBeFcl1vf+ize40vu5ZF0D7200e4u3Co99ZGm70AaKoob2rAIqtJxAzODSj7ZjbN SXMBGfd4p92+wTlXp3DVHD5cgU9rquRafnzNyBulcOUxUg5V2OyanJ5Ookzvnygauvuk z2PQMAHKF971jrRCvfHGMjT9QFq2m+FVm0+xtRYejwEcvrk6hKFroQ+vSAVUbQmPNKxy yLFw== X-Gm-Message-State: AOAM530UF/gn0DRb9szQTzAbES5QNdiyblooSqMszFHFTUB9aQ76UmHy DzBYQpo+IiX8yxEOSieM0BQ4+Q== X-Received: by 2002:a9d:4588:: with SMTP id x8mr14555151ote.169.1607373216384; Mon, 07 Dec 2020 12:33:36 -0800 (PST) Received: from eggly.attlocal.net (172-10-233-147.lightspeed.sntcca.sbcglobal.net. [172.10.233.147]) by smtp.gmail.com with ESMTPSA id n6sm2874818ota.73.2020.12.07.12.33.34 (version=TLS1 cipher=ECDHE-ECDSA-AES128-SHA bits=128/128); Mon, 07 Dec 2020 12:33:35 -0800 (PST) Date: Mon, 7 Dec 2020 12:33:18 -0800 (PST) From: Hugh Dickins X-X-Sender: hugh@eggly.anvils To: Roman Gushchin cc: Michal Hocko , Muchun Song , Greg KH , rafael@kernel.org, Alexey Dobriyan , Andrew Morton , Johannes Weiner , Vladimir Davydov , Hugh Dickins , Will Deacon , Mike Rapoport , Thomas Gleixner , esyr@redhat.com, peterx@redhat.com, krisman@collabora.com, Suren Baghdasaryan , avagin@openvz.org, Marco Elver , Randy Dunlap , Joonsoo Kim , LKML , linux-fsdevel , Linux Memory Management List , Cgroups Subject: Re: [External] Re: [RESEND PATCH v2 00/12] Convert all vmstat counters to pages or bytes In-Reply-To: <20201207195141.GB2238414@carbon.dhcp.thefacebook.com> Message-ID: References: <20201206101451.14706-1-songmuchun@bytedance.com> <20201207130018.GJ25569@dhcp22.suse.cz> <20201207150254.GL25569@dhcp22.suse.cz> <20201207195141.GB2238414@carbon.dhcp.thefacebook.com> User-Agent: Alpine 2.11 (LSU 23 2013-08-11) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, 7 Dec 2020, Roman Gushchin wrote: > On Mon, Dec 07, 2020 at 04:02:54PM +0100, Michal Hocko wrote: > > > > As I've said the THP accounting change makes more sense to me because it > > allows future changes which are already undergoing so there is more > > merit in those. > > +1 > And this part is absolutely trivial. It does need to be recognized that, with these changes, every THP stats update overflows the per-cpu counter, resorting to atomic global updates. And I'd like to see that mentioned in the commit message. But this change is consistent with 4.7's 8f182270dfec ("mm/swap.c: flush lru pvecs on compound page arrival"): we accepted greater overhead for greater accuracy back then, so I think it's okay to do so for THP stats. Hugh