Re: [RFC PATCH V1 1/1] sched/numa: Enhance vma scanning logic

From: Raghavendra K T
Date: Thu Jan 19 2023 - 05:25:32 EST


On 1/19/2023 3:09 PM, Mike Rapoport wrote:
Hi,

On Mon, Jan 16, 2023 at 07:05:34AM +0530, Raghavendra K T wrote:
During the Numa scanning make sure only relevant vmas of the
tasks are scanned.

Please add more detailed description about what are the issues with the
current scanning this patch aims to solve.

Thank you for the review Mike. Sure will add more detail in the patch
commit in V2


Logic:
1) For the first two time allow unconditional scanning of vmas
2) Store recent 4 unique tasks (last 8bits of PIDs) accessed the vma.
False negetives in case of collison should be fine here.

^ negatives

will take care of this and one below

3) If more than 4 pids exist assume task indeed accessed vma to
to avoid false negetives

Co-developed-by: Bharata B Rao <bharata@xxxxxxx>
(initial patch to store pid information)

Suggested-by: Mel Gorman <mgorman@xxxxxxxxxxxxxxxxxxx>
Signed-off-by: Bharata B Rao <bharata@xxxxxxx>
Signed-off-by: Raghavendra K T <raghavendra.kt@xxxxxxx>
---
[...]