Received: by 2002:a05:7412:518d:b0:e2:908c:2ebd with SMTP id fn13csp332343rdb; Thu, 5 Oct 2023 07:18:44 -0700 (PDT) X-Google-Smtp-Source: AGHT+IEn/kzN5Zjkyxu4g3LPa/ZqhwI7UFdcfzeugl9GqdopunO+eklxXrpaOVenu7xprbBzZ8kR X-Received: by 2002:a17:90b:1213:b0:279:12e4:eab6 with SMTP id gl19-20020a17090b121300b0027912e4eab6mr4406561pjb.7.1696515523834; Thu, 05 Oct 2023 07:18:43 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1696515523; cv=none; d=google.com; s=arc-20160816; b=p4K/jftE5OWsaLBXrk1QWzC/Gx6p2ddtCHeX9WqN5oF5x9L1seWwj1f7j8BTgaJAbR UVe5ie07onJ1ZXyJ+oM6HIx3JtP8NKcGFYCpV9eN+G3vKbmHG4tVlnMmsn0KY2ij/g1X iQUXFPTdptUG/2cJ0uWTuuunXy6mubzTEa44sabbMk2enuih8yfwXX6ljw32RX832iHU exCAX4ZAfXYNfljxWkyQ5Pol3pEuGoQjuo6dP8fth4i70pAshvRarwjqc8CtXfFYI7xr Kc3yrL7y6LVSUyOusCIuTr2ekDNKEJlm/9cVyJFJHiiHR8f4bh9Lvec6tPVacEtxRciE Qxaw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=I5mDtqn4ke7EOccXi4sHIRDZaPhR32uiSgJHqJga3Hg=; fh=qtO/9IAfnmF+4fTJvCfuKuKDiSKqjdKkXYj6pH96dWw=; b=XdM6R3uFTEmlWKeupncuVEpnfenPmt6zqilrSsQCNl1MEKnqGdCOPbYy5u3ydr4HEg LhYjLxCUsinIOzvtD/DsPYyGsEzAUts0JFCPos79HSOAWyRunzAFwoGAGt1H2R0MpZBE 7dpKyFcU6F7aH+wyvrWUUSlKmFDvBr07BGiy09uKglsLmDP3cjZHLJf+Jv1SqcYLZMBc xS2bw4TG/JCwdkoo/0Bgmr7wNCGCVz5raXRqy7ZDbFh7lsGBahzxNDfhUpBWa+aPPGQ3 O3jiDWaz1JeNRANQNyLWfbLaXZd2Ku0zqghehp/kkMc+xIbaa5JO6XoGLLqO/MskLwrH y9Tg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@suse.com header.s=susede1 header.b=Gb7qt86C; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.32 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=suse.com Return-Path: Received: from agentk.vger.email (agentk.vger.email. [23.128.96.32]) by mx.google.com with ESMTPS id s8-20020a17090a1c0800b00262ff3a4545si3681421pjs.169.2023.10.05.07.18.43 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 05 Oct 2023 07:18:43 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.32 as permitted sender) client-ip=23.128.96.32; Authentication-Results: mx.google.com; dkim=pass header.i=@suse.com header.s=susede1 header.b=Gb7qt86C; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.32 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=suse.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by agentk.vger.email (Postfix) with ESMTP id F372380A32FF; Thu, 5 Oct 2023 07:18:17 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at agentk.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233558AbjJEORI (ORCPT + 99 others); Thu, 5 Oct 2023 10:17:08 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43606 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233825AbjJEOPE (ORCPT ); Thu, 5 Oct 2023 10:15:04 -0400 Received: from smtp-out2.suse.de (smtp-out2.suse.de [IPv6:2001:67c:2178:6::1d]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id BED969EE6; Thu, 5 Oct 2023 02:06:34 -0700 (PDT) Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by smtp-out2.suse.de (Postfix) with ESMTPS id 5D0D91F892; Thu, 5 Oct 2023 09:06:31 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=susede1; t=1696496791; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=I5mDtqn4ke7EOccXi4sHIRDZaPhR32uiSgJHqJga3Hg=; b=Gb7qt86CRw4Q2hcmLffRyrjdC42UtFGR7X8XobT6nxzGeZd1VOa3nm/yNyp5QIqvIBoetq WouqBXaum/wzpjeQ7kyDLPtsvqQOVgrVLp6sUQ9Lkg0DaXIx5lOlQKwx2ZjFWmnT74HH46 qlzfJnMjAXx/r9L0i3c+S+83QdscROA= Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by imap2.suse-dmz.suse.de (Postfix) with ESMTPS id 22851139C2; Thu, 5 Oct 2023 09:06:31 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap2.suse-dmz.suse.de with ESMTPSA id bbGdB5d8HmWVcgAAMHmgww (envelope-from ); Thu, 05 Oct 2023 09:06:31 +0000 Date: Thu, 5 Oct 2023 11:06:29 +0200 From: Michal =?utf-8?Q?Koutn=C3=BD?= To: Johannes Weiner Cc: Yosry Ahmed , Andrew Morton , Shakeel Butt , Michal Hocko , Roman Gushchin , Muchun Song , linux-mm@kvack.org, cgroups@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH v2 1/2] mm: memcg: refactor page state unit helpers Message-ID: <542ggmgjc27yoosxg466c6n4mzcad2z63t3wdbzevzm43g7xlt@5l7qaepzbth6> References: <20230922175741.635002-1-yosryahmed@google.com> <20230922175741.635002-2-yosryahmed@google.com> <20231004183619.GB39112@cmpxchg.org> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="cdqoo3w6fdlwt4bn" Content-Disposition: inline In-Reply-To: <20231004183619.GB39112@cmpxchg.org> X-Spam-Status: No, score=-0.8 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on agentk.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (agentk.vger.email [0.0.0.0]); Thu, 05 Oct 2023 07:18:18 -0700 (PDT) --cdqoo3w6fdlwt4bn Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Wed, Oct 04, 2023 at 02:36:19PM -0400, Johannes Weiner wrote: > Yes, it's because of node resolution which event counters generally > don't have. Some of the refault events influence node-local reclaim > decisions, see mm/vmscan.c::snapshot_refaults(). >=20 > There are a few other event counters in the stat array that people > thought would be useful to have split out in > /sys/devices/system/node/nodeN/vmstat to understand numa behavior > better. >=20 > It's a bit messy. >=20 > Some events would be useful to move to 'stats' for the numa awareness, > such as the allocator stats and reclaim activity. >=20 > Some events would be useful to move to 'stats' for the numa awareness, > but don't have the zone resolution required by them, such as > kswapd/kcompactd wakeups. Thanks for the enlightenment. > Some events aren't numa specific, such as oom kills, drop_pagecache. These are oddballs indeed. As with the normalization patchset these are counted as PAGE_SIZE^W 1 error but they should rather be an infinite error (to warrant a flush). So my feedback to this series is: - patch 1/2 -- creating two classes of units is consequence of unclarity between state and events (as in event=3D=CE=94state/=CE=94t) and resoluti= on (global vs per-node), so the better approach would be to tidy this up, - patch 2/2 -- it could use the single unit class that exists,=20 it'll bound the error of printed numbers afterall (and can be changed later depending on how it affects internal consumers). My 0.02=E2=82=AC, Michal --cdqoo3w6fdlwt4bn Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iHUEABYKAB0WIQQpEWyjXuwGT2dDBqAGvrMr/1gcjgUCZR58lAAKCRAGvrMr/1gc jrLvAP91rXrkJJRIRNaOZGR9o6ggxOXbwA7LGaBGQc6FSZyomAD/VZ3zJwOcG0uw rVioAhpVnfjLpk/ADrszcFpJ7FRPzQI= =s1VT -----END PGP SIGNATURE----- --cdqoo3w6fdlwt4bn--