[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <f1f71150-b3e9-7d15-7a0b-57673a9021d5@linux.alibaba.com>
Date: Tue, 23 Apr 2019 17:32:28 +0800
From: 王贇 <yun.wang@...ux.alibaba.com>
To: Peter Zijlstra <peterz@...radead.org>
Cc: hannes@...xchg.org, mhocko@...nel.org, vdavydov.dev@...il.com,
Ingo Molnar <mingo@...hat.com>, linux-kernel@...r.kernel.org,
linux-mm@...ck.org
Subject: Re: [RFC PATCH 1/5] numa: introduce per-cgroup numa balancing
locality, statistic
On 2019/4/23 下午4:46, Peter Zijlstra wrote:
> On Mon, Apr 22, 2019 at 10:11:24AM +0800, 王贇 wrote:
>> + * 0 -- remote faults
>> + * 1 -- local faults
>> + * 2 -- page migration failure
>> + * 3 -- remote page accessing after page migration
>> + * 4 -- local page accessing after page migration
>
>> @@ -2387,6 +2388,11 @@ void task_numa_fault(int last_cpupid, int mem_node, int pages, int flags)
>> memset(p->numa_faults_locality, 0, sizeof(p->numa_faults_locality));
>> }
>>
>> + p->numa_faults_locality[mem_node == numa_node_id() ? 4 : 3] += pages;
>> +
>> + if (mem_node == NUMA_NO_NODE)
>> + return;
>
> I'm confused on the meaning of 3 & 4. It says 'after page migration' but
> 'every' access if after 'a' migration. But even more confusingly, you
> even account it if we know the page has never been migrated.
>
> So what are you really counting
Here is try to get the times of a task accessing the local or remote pages,
and on no migration cases we still account since it's also one time of accessing,
remotely or locally.
'after page migration' means this accounting need to understand the real page
position after PF, what ever migration failure or succeed, whatever page move to
local/remote or untouched, we want to know the times a task accessed the page
locally or remotely, on numa balancing period.
Regards,
Michael Wang
>
Powered by blists - more mailing lists