Received: by 10.192.165.148 with SMTP id m20csp1162580imm; Wed, 2 May 2018 15:29:30 -0700 (PDT) X-Google-Smtp-Source: AB8JxZpxmQYNHG5GVgdXQT2MsSs4cyXI5kuxoQ5F6/cPabUSA2CLTrnfQp8YKPkL34HKjBltQczE X-Received: by 2002:a17:902:bd46:: with SMTP id b6-v6mr21777040plx.170.1525300170642; Wed, 02 May 2018 15:29:30 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1525300170; cv=none; d=google.com; s=arc-20160816; b=Cke6ynIiZq9HX/RjHSOnmHusJAc0ll9DKQ2xqXuD+lLz4+mBfTRB0DZ80pP+jLQP3X MxIJSdfSpAshrFNc3ID0WIIOAQsEFQcmntpDySukQ/Wf/D0lYE/38pKTmE4aLLJwDWLL nUn+rQj9qBkpfb9rIjoCjQ93TmrQw48Yexj3VikJuxhFWxj0Ow0tP2LVHpPdLYkF65L6 6IzFV/oXf2Y2oavZxJk9bJfzXMeevTRQElnp1uIYKnjd+ZsBul9vAORzzslNt8g3pQfq QL6/HVi/VCgUe0Pxl6LbONevhfhjT5gGBFP7NYyfKvHN0vMlUG8LDco68yN8iFbkK1c9 eAUw== 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:openpgp:from:cc:references:to:subject :arc-authentication-results; bh=4oUm7qrmuO5J5HuFrZRwQoZ5XX/OEBPugRdPAmshbdc=; b=hE+8mx1+C+ENs9qzWc+yqexTZlPSBcZBvHnSPnzZooqx8UhElea71pjes09RRcc7gr Nec/tq8m/kXn0OOXDjRUJofsY4LrbcaZccV/tAzt1WJX+fj6ygaryo/dUrQPwuTf51We i5qr4QERuLR+yOHEpOeGNWjLnCgeNpY4LoAFjZIv5+xizJDF6RRjW5xCVlVJYuQCB0fW 9K05n5kuqvgK+48NclNOCyQSnTv0gyJEf9KCKmEyeX4snZpLmcuVqJPiPJCSZNOEKgze 87Po65FdmSSuIrRaTllmEVYAsN635BRrAgO+Q/yIfaDmPCwmPIsBLAi8v8DKNVpk80Nm ucMQ== 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id y9-v6si7333630pgc.601.2018.05.02.15.29.15; Wed, 02 May 2018 15:29:30 -0700 (PDT) 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751538AbeEBW3D (ORCPT + 99 others); Wed, 2 May 2018 18:29:03 -0400 Received: from mga17.intel.com ([192.55.52.151]:46566 "EHLO mga17.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751261AbeEBW3B (ORCPT ); Wed, 2 May 2018 18:29:01 -0400 X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga005.jf.intel.com ([10.7.209.41]) by fmsmga107.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 02 May 2018 15:29:00 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.49,356,1520924400"; d="scan'208";a="221149976" Received: from ray.jf.intel.com (HELO [10.7.201.133]) ([10.7.201.133]) by orsmga005.jf.intel.com with ESMTP; 02 May 2018 15:29:00 -0700 Subject: Re: [RFC PATCH] Add /proc//numa_vamaps for numa node information To: Andrew Morton , Prakash Sangappa References: <1525240686-13335-1-git-send-email-prakash.sangappa@oracle.com> <20180502143323.1c723ccb509c3497050a2e0a@linux-foundation.org> Cc: linux-kernel@vger.kernel.org, linux-mm@kvack.org, linux-api@vger.kernel.org, mhocko@suse.com, kirill.shutemov@linux.intel.com, n-horiguchi@ah.jp.nec.com, drepper@gmail.com, rientjes@google.com, Naoya Horiguchi From: Dave Hansen Openpgp: preference=signencrypt Message-ID: <2ce01d91-5fba-b1b7-2956-c8cc1853536d@intel.com> Date: Wed, 2 May 2018 15:28:59 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.7.0 MIME-Version: 1.0 In-Reply-To: <20180502143323.1c723ccb509c3497050a2e0a@linux-foundation.org> 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 05/02/2018 02:33 PM, Andrew Morton wrote: > On Tue, 1 May 2018 22:58:06 -0700 Prakash Sangappa wrote: >> For analysis purpose it is useful to have numa node information >> corresponding mapped address ranges of the process. Currently >> /proc//numa_maps provides list of numa nodes from where pages are >> allocated per VMA of the process. This is not useful if an user needs to >> determine which numa node the mapped pages are allocated from for a >> particular address range. It would have helped if the numa node information >> presented in /proc//numa_maps was broken down by VA ranges showing the >> exact numa node from where the pages have been allocated. I'm finding myself a little lost in figuring out what this does. Today, numa_maps might us that a 3-page VMA has 1 page from Node 0 and 2 pages from Node 1. We group *entirely* by VMA: 1000-4000 N0=1 N1=2 We don't want that. We want to tell exactly where each node's memory is despite if they are in the same VMA, like this: 1000-2000 N1=1 2000-3000 N0=1 3000-4000 N1=1 So that no line of output ever has more than one node's memory. It *appears* in this new file as if each contiguous range of memory from a given node has its own VMA. Right? This sounds interesting, but I've never found myself wanting this information a single time that I can recall. I'd love to hear more. Is this for debugging? Are apps actually going to *parse* this file? How hard did you try to share code with numa_maps? Are you sure we can't just replace numa_maps? VMAs are a kernel-internal thing and we never promised to represent them 1:1 in our ABI. Are we going to continue creating new files in /proc every time a tiny new niche pops up? :)