Received: by 2002:a25:1506:0:0:0:0:0 with SMTP id 6csp1946617ybv; Sun, 23 Feb 2020 19:06:16 -0800 (PST) X-Google-Smtp-Source: APXvYqzJ+lOzNiLlZ55QudXcGZ3gha6p0mN8iDSH57LoNGuL2hwuzc7oc6MQiiis9wLgwtJSBf5S X-Received: by 2002:a9d:7f81:: with SMTP id t1mr35949427otp.95.1582513576620; Sun, 23 Feb 2020 19:06:16 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1582513576; cv=none; d=google.com; s=arc-20160816; b=OE8RhJpDZEYatKbKxJk1F/mMEJr4yCE1Ju35QW21hktT8kGDGZbkqUWjnZ6+/+K3BX eYn8+OTV9UaeuyGQralNSu8Uvg6KxBcPkWPTwgI1qgoAU7GgqMd7BT5FuTgl8LLg8oXM zIkYqmh7Z0qFHvRoUugfLpQtgADMJQpc1mh+n2sMZJdBF+xWb3ahmDeL6+pna5dyEDDt uKre58v0UMN9llG13C6CsDYcztj95BeXPvMSGNc9/EWoEeKVttJ1Mg8R2ItpcWrd/a4c qonwHdBWqfHh1bGgZ+YSnj3k31csgQ0J2uYcSAl0h4LefskPOQuytuSFpqN4eWOEbXRO VxrQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject; bh=VpXJB2Yx3/0vxpAjmzvZOwuRPvI4mXpC+oTOxAJ8Hf0=; b=WFuPk+zNuQzK8kzHubh+tXThM3dn0GoupoO/MecgVGpV0155nOzzj1mRmhINPuEZHr xdKjKQ3O6Z0Hydw5UnCEi94fU0p/0W8jcX47KFutpUPdU6gnxDuWw3g4Pja+1qBcrR92 ESrE62b0ttMVbKyTOnMhP63/HFqKerpfIHfEWMKPXLzHZMMWSE+8mkF1bRJYW9mTd522 3QjH93fExhl1fEhU7qQUEAFfYLOTtEaKeN5V1wbQNCG8ZuN++hS2cLkr4m7YQG6GSbWW zi1/7TQbNznPVd0pFch9cIIlmxWHfmUoFOmiNsHJ42diFaAFt6e782g/yyrvpABG9a8l 2irQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=alibaba.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id w77si4633873oif.216.2020.02.23.19.06.03; Sun, 23 Feb 2020 19:06:16 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=alibaba.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727215AbgBXDF5 (ORCPT + 99 others); Sun, 23 Feb 2020 22:05:57 -0500 Received: from out30-133.freemail.mail.aliyun.com ([115.124.30.133]:37547 "EHLO out30-133.freemail.mail.aliyun.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727156AbgBXDF4 (ORCPT ); Sun, 23 Feb 2020 22:05:56 -0500 X-Alimail-AntiSpam: AC=PASS;BC=-1|-1;BR=01201311R191e4;CH=green;DM=||false|;DS=||;FP=0|-1|-1|-1|0|-1|-1|-1;HT=e01f04428;MF=yun.wang@linux.alibaba.com;NM=1;PH=DS;RN=18;SR=0;TI=SMTPD_---0TqheseS_1582513549; Received: from testdeMacBook-Pro.local(mailfrom:yun.wang@linux.alibaba.com fp:SMTPD_---0TqheseS_1582513549) by smtp.aliyun-inc.com(127.0.0.1); Mon, 24 Feb 2020 11:05:51 +0800 Subject: Re: [PATCH RESEND v8 1/2] sched/numa: introduce per-cgroup NUMA locality info To: Mel Gorman Cc: Peter Zijlstra , Ingo Molnar , Juri Lelli , Vincent Guittot , Dietmar Eggemann , Steven Rostedt , Ben Segall , Luis Chamberlain , Kees Cook , Iurii Zaikin , Michal Koutn? , linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org, linux-doc@vger.kernel.org, "Paul E. McKenney" , Randy Dunlap , Jonathan Corbet References: <20200214151048.GL14914@hirez.programming.kicks-ass.net> <20200217115810.GA3420@suse.de> <881deb50-163e-442a-41ec-b375cc445e4d@linux.alibaba.com> <20200217141616.GB3420@suse.de> <114519ab-4e9e-996a-67b8-4f5fcecba72a@linux.alibaba.com> <20200221142010.GT3420@suse.de> From: =?UTF-8?B?546L6LSH?= Message-ID: <2def511f-4eb4-4c70-cd68-415fa63453eb@linux.alibaba.com> Date: Mon, 24 Feb 2020 11:05:49 +0800 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.13; rv:68.0) Gecko/20100101 Thunderbird/68.4.1 MIME-Version: 1.0 In-Reply-To: <20200221142010.GT3420@suse.de> Content-Type: text/plain; charset=UTF-8 Content-Language: en-US Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 2020/2/21 下午10:20, Mel Gorman wrote: [snip] >>> >>> Which is a very interesting corner case in itself but also one that >>> could have potentially have been inferred from monitoring /proc/vmstat >>> numa_pte_updates or on a per-task basis by monitoring /proc/PID/sched and >>> watching numa_scan_seq and total_numa_faults. Accumulating the information >>> on a per-cgroup basis would require a bit more legwork. >> >> That's not working for daily monitoring... >> > > Indeed although at least /proc/vmstat is cheap to monitor and it could > at least be tracked if the number of NUMA faults are abnormally low or > the ratio of remote to local hints are problematic. > >> Besides, compared with locality, this require much more deeper understand >> on the implementation, which could even be tough for NUMA developers to >> assemble all these statistics together. >> > > My point is that even with the patch, the definition of locality is > subtle. At a single point in time, the locality might appear to be low > but it's due to an event that happened far in the past. Agree, the locality's meaning just keep changing... only those who understand the implementation can figure out the useful information. > >>> >>>> Maybe not a good example, but we just try to highlight that NUMA Balancing >>>> could have issue in some cases, and we want them to be exposed, somehow, >>>> maybe by the locality. >>>> >>> >>> Again, I'm somewhat neutral on the patch simply because I would not use >>> the information for debugging problems with NUMA balancing. I would try >>> using tracepoints and if the tracepoints were not good enough, I'd add or >>> fix them -- similar to what I had to do with sched_stick_numa recently. >>> The caveat is that I mostly look at this sort of problem as a developer. >>> Sysadmins have very different requirements, especially simplicity even >>> if the simplicity in this case is an illusion. >> >> Fair enough, but I guess PeterZ still want your Ack, so neutral means >> refuse in this case :-( >> > > I think the patch is functionally harmless and can be disabled but I also > would be wary of dealing with a bug report that was based on the numbers > provided by the locality metric. The bulk of the work related to the bug > would likely be spent on trying to explain the metric and I've dealt with > quite a few bugs that were essentially "We don't like this number and think > something is wrong because of it -- fix it". Even then, I would want the > workload isolated and then vmstat recorded over time to determine it's > a persistent problem or not. That's the reason why I'm relucant to ack it. > > I fully acknowledge that this may have value for sysadmins and may be a > good enough reason to merge it for environments that typically build and > configure their own kernels. I doubt that general distributions would > enable it but that's a guess. Thanks for the kindly explain, I get the point. False alarm maybe fine to admin, but could be nightmare if the user keep asking why, I suppose those who want to do some improvement on NUMA may be interested :-P Anyway, I understand there is a gap between general requirement and this locality idea, and it's really hard to be fulfill... > >> BTW, how do you think about the documentation in second patch? >> > > I think the documentation is great, it's clear and explains itself well. > >> Do you think it's necessary to have a doc to explain NUMA related statistics? >> > > It would be nice but AFAIK, the stats in vmstats are not documented. > They are there because recording them over time can be very useful when > dealing with user bug reports. Another TODO then :-) Regards, Michael Wang >