Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp7492695pxb; Thu, 18 Feb 2021 11:29:14 -0800 (PST) X-Google-Smtp-Source: ABdhPJwmGlYXj34s4t193o+re/M1CvVfBte1Am6hwIEPepgtlEM8ZMe8aSiA9+ymg9tAAOMBON4S X-Received: by 2002:a17:906:710d:: with SMTP id x13mr5256163ejj.383.1613676554640; Thu, 18 Feb 2021 11:29:14 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1613676554; cv=none; d=google.com; s=arc-20160816; b=kgntbEd+trnM0G0XQ6J6jqfu2kCo0crHCBSpfVPnqhuXXn9z9/1KNXma4EAs4mWlhX cO53yb/earcbTmhnP/1ipMZRPAUzPwvBjpvHs3Tc2gcsyUrOKunGJ7Jg+7hXj1X+XwG2 KaoC0Z4xKg6ltpf0r3FwBXU3wh5n1luzFqzQAJkB1Llttffwc+ikqx/Ncz6Xuk9ARrH5 cGu9XJ1DswQUw5O1wco1lnMMSoxkTss4lw/FDDfile1fLeggMq941TExkgcwLbxffzzX kIQeTPOj/jpdHldnrpy+gHaXxwFyHrVWiTQh6FGc5MYPRW64pKuUuPPJLwO7JSuGUhEK kDGw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:content-language :in-reply-to:mime-version:user-agent:date:message-id:from:references :cc:to:subject:ironport-sdr:ironport-sdr; bh=v94PW4bJ/SYWYEJvQwOFpW5XX7+857yDbuvPrQPGAKY=; b=PPKJOwBE44kguV7zj5dNu/7Rj2G8/ilmrR/o8Uxj2Hqzxbnfxm+6KIQBgriaMgE5wP wgklr17jfMMk87NAMOUzhZkHwhUX4BfDo9yEXg873r2IyD3mxVntwBDHY+iDY1fjL5cF +yLtmp+tF+Jo5kbrq5DkhUTb7/AIybyVNd0mC+b0ljmFB5kFcSa12ok5oWWrDnEN5oOZ /Ldjj96mep+hKc+M7m5gvybftoTi5uz5evZq1D0WEixpBUhsafzOO7dLVnybt14mIRXp DGNlJWnV5dpZiNI16gqVQ4CcL9Xz1vWDbKa0BSMKXR4QMuOepXFCHLpL44yW8ar9+jXj aVTg== 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id d8si3583312ejw.416.2021.02.18.11.28.50; Thu, 18 Feb 2021 11:29:14 -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; 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=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232241AbhBRT1w (ORCPT + 99 others); Thu, 18 Feb 2021 14:27:52 -0500 Received: from mga02.intel.com ([134.134.136.20]:47036 "EHLO mga02.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232417AbhBRSiT (ORCPT ); Thu, 18 Feb 2021 13:38:19 -0500 IronPort-SDR: OaEJHUpjNaMZwe5N5kbFFW2c7vyWdzewFPtA8KVCuevQCLgaM3QrYu5eazSE4ixungQ6oyGOwT i8ucj0sJGA8g== X-IronPort-AV: E=McAfee;i="6000,8403,9899"; a="170740653" X-IronPort-AV: E=Sophos;i="5.81,187,1610438400"; d="scan'208";a="170740653" Received: from fmsmga002.fm.intel.com ([10.253.24.26]) by orsmga101.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 18 Feb 2021 10:30:26 -0800 IronPort-SDR: K3prdcyMQiILvxrHbSlBhLyrBhdsusQb3Ie+7kLhrXL3PlDG9elq+aDuhFcd4h4iwFlph3eae9 lRpPRtrwhOkQ== X-IronPort-AV: E=Sophos;i="5.81,187,1610438400"; d="scan'208";a="428315976" Received: from schen9-mobl.amr.corp.intel.com ([10.254.101.217]) by fmsmga002-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 18 Feb 2021 10:30:26 -0800 Subject: Re: [PATCH v2 1/3] mm: Fix dropped memcg from mem cgroup soft limit tree To: Michal Hocko Cc: Andrew Morton , Johannes Weiner , Vladimir Davydov , Dave Hansen , Ying Huang , linux-mm@kvack.org, cgroups@vger.kernel.org, linux-kernel@vger.kernel.org References: <8d35206601ccf0e1fe021d24405b2a0c2f4e052f.1613584277.git.tim.c.chen@linux.intel.com> From: Tim Chen Message-ID: Date: Thu, 18 Feb 2021 10:30:20 -0800 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.6.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 2/18/21 12:24 AM, Michal Hocko wrote: > > I have already acked this patch in the previous version along with Fixes > tag. It seems that my review feedback has been completely ignored also > for other patches in this series. Michal, My apology. Our mail system screwed up and there are some mail missing from our mail system that I completely missed your mail. Only saw them now after I looked into the lore.kernel.org. Responding to your comment: >Have you observed this happening in the real life? I do agree that the >threshold based updates of the tree is not ideal but the whole soft >reclaim code is far from optimal. So why do we care only now? The >feature is essentially dead and fine tuning it sounds like a step back >to me. Yes, I did see the issue mentioned in patch 2 breaking soft limit reclaim for cgroup v1. There are still some of our customers using cgroup v1 so we will like to fix this if possible. For patch 3 regarding the uncharge_batch, it is more of an observation that we should uncharge in batch of same node and not prompted by actual workload. Thinking more about this, the worst that could happen is we could have some entries in the soft limit tree that overestimate the memory used. The worst that could happen is a soft page reclaim on that cgroup. The overhead from extra memcg event update could be more than a soft page reclaim pass. So let's drop patch 3 for now. Let me know if you will like me to resend patch 1 with the fixes tag for commit 4e41695356fb ("memory controller: soft limit reclaim on contention") and if there are any changes I should make for patch 2. Thanks. Tim