Received: by 2002:a05:6a10:2726:0:0:0:0 with SMTP id ib38csp2202921pxb; Fri, 25 Mar 2022 12:58:54 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzmER/rty4xSPBDbA7Pf9CpoFDEfI0bXrvG4uzrij+Md/vq6S1Da9lMhvzEJo1/bIN1haQc X-Received: by 2002:a05:6a00:2181:b0:4f6:f1b1:1ba7 with SMTP id h1-20020a056a00218100b004f6f1b11ba7mr11798402pfi.73.1648238334196; Fri, 25 Mar 2022 12:58:54 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1648238334; cv=none; d=google.com; s=arc-20160816; b=TQB5fbS21fnpRDS0/Nnvc7Uj7KJ2LS/LcTFs3XsZD9p4y6YMnYJawi01v7fxfgPdG9 gFOWCyjnpOxFUbJxLSV6bngF+fHiVvEGN6hpz7/NzFFEXTw+XlQZJI1iV9uYC3vAj/sb gT/ofXTybXQNrHg0uAewKdb3yIgDVKN1i/KTE6iuy+5z7lowxTfY76in+WrpWXXDPUGH hUZ+MmozatwNT4w0mgosLm7XiKyl43LEIBllk0mahXfEikI4Z3BIdWucgAkZp74kCSPa Z4JyxzzZL/I0KjBevFzZfFKyfOCEvkljW/g3bal8Tjcoy7BJfIqsALizzP3Avx1m7Vpc oG4Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:to:references:message-id:cc:date:in-reply-to :from:subject:mime-version:content-transfer-encoding:dkim-signature; bh=+Xdg6AguU1tCjET4IpuuuOj6DcGbMJAnyZKDx5p9X6o=; b=Hlg1gUmX+3QN6JgRXc59FvRo3/52tZnw/Y1J1E/zbdsHXjUylKZzmwvEPFHYDCqKdh P0XfO87y3O8Uz/CtMxBo/cHNNSYhtud9F24x12UT6UGBHsBn1wBxBLNajSS4xFzfuTO8 o0oB82rQTom5KZSbQRYR/JQ/HhhQcxxkuNjPTL+vEMVkgJH4rb6LziTrfTeaDNg0+a/P CCoS+xCBcAWjwHSH8e7/E+5Zx2gJJlBNaDdpcUbqbIiFcUGe6YKPpdFh3CCirW9YCiHQ GnpAACg6/1p3Xjkw0yEY9p/iNVGslriI176FYVNIWnak1gIh9pAXKeklHZ/JyP1+OaKb 7wLg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linux.dev header.s=key1 header.b=CaznleEk; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linux.dev Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [23.128.96.19]) by mx.google.com with ESMTPS id t8-20020aa79468000000b004fa3a8e0011si3900040pfq.200.2022.03.25.12.58.53 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 25 Mar 2022 12:58:54 -0700 (PDT) Received-SPF: softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) client-ip=23.128.96.19; Authentication-Results: mx.google.com; dkim=pass header.i=@linux.dev header.s=key1 header.b=CaznleEk; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linux.dev Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id E9601352E32; Fri, 25 Mar 2022 11:47:26 -0700 (PDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1352579AbiCXSSx (ORCPT + 99 others); Thu, 24 Mar 2022 14:18:53 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33774 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1352575AbiCXSSv (ORCPT ); Thu, 24 Mar 2022 14:18:51 -0400 Received: from out1.migadu.com (out1.migadu.com [91.121.223.63]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 2D361B7170; Thu, 24 Mar 2022 11:17:19 -0700 (PDT) Content-Type: text/plain; charset=utf-8 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.dev; s=key1; t=1648145837; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=+Xdg6AguU1tCjET4IpuuuOj6DcGbMJAnyZKDx5p9X6o=; b=CaznleEkIgnUPwdpezvS7Q1Z4Lx0QM+qd453HpZhRxWImtUouqJZERSIMyPP1D2gE8ZEgK hunDJ2I4gzVQNoBZ4dAQD8M976MYphFJnDpz5hcIVyr8TlmscQS2WpsWbWgfK1i5SJvIAc 0p6Mq5sqgguQ1ED1eaSfq88c1oCQ5Go= Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Subject: Re: [RFC PATCH] mm: memcg: Do not count memory.low reclaim if it does not happen X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. From: Roman Gushchin In-Reply-To: <20220324095157.GA16685@blackbody.suse.cz> Date: Thu, 24 Mar 2022 11:17:14 -0700 Cc: cgroups@vger.kernel.org, linux-mm@kvack.org, linux-kernel@vger.kernel.org, Richard Palethorpe , Andrew Morton , Shakeel Butt , Michal Hocko , Vlastimil Babka , "Matthew Wilcox (Oracle)" , Muchun Song , Johannes Weiner , Yang Shi , Suren Baghdasaryan , Tejun Heo , Chris Down Message-Id: <5049EBC3-5BAE-4509-BA63-1F4A7D913517@linux.dev> References: <20220324095157.GA16685@blackbody.suse.cz> To: =?utf-8?Q?Michal_Koutn=C3=BD?= X-Migadu-Flow: FLOW_OUT X-Migadu-Auth-User: linux.dev X-Spam-Status: No, score=-2.0 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,RDNS_NONE,SPF_HELO_NONE,T_SCC_BODY_TEXT_LINE autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org > On Mar 24, 2022, at 2:52 AM, Michal Koutn=C3=BD wrote: >=20 > =EF=BB=BFOn Wed, Mar 23, 2022 at 02:44:24PM -0700, Roman Gushchin wrote: >> Does it mean that in the following configuration: >> `parent .low=3D50M >> ` s1 .low=3D0M .current=3D50M >> ` s2 .low=3D0M .current=3D50M >> there will be no memory.events::low at all? (assuming the recursive thing= is on) >=20 > True, no memory.events:low among siblings. > Number of memory.events:low in the parent depends on how much has to be > reclaimed (>50M means carving into parent's protection, hence it'll be > counted). Ok, so it=E2=80=99s not really about the implementation details of the recla= im mechanism (I mean rounding up to the batch size etc), it=E2=80=99s a more= generic change: do not generate low events for cgroups not explicitly prote= cted by a non-zero memory.low value. Idk, I don=E2=80=99t have a strong argument against this change (except that= it changes the existing behavior), but I also don=E2=80=99t see why such ev= ents are harmful. Do you mind elaborating a bit more? Thank you!=