Skip to content

RFC mm/damon: add a DAMOS filter type for page granularity access recheck

SeongJae Park damon linux-mm lkml 2 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v2 RFC Latest4 patches 1 replyIn review
  2. v1 RFC3 patches 1 replySuperseded

Changes in v2 from the cover letter

(https://lore.kernel.org/r/[email protected])
- Rename __damon_pa_young() to damon_folio_young_one()
- Mark the folio as old from the filter for the next check

Patches in v2 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/4mm/damon/paddr: implement damon_folio_young()mm/damon/paddr.c+19 -130 replies
2/4mm/damon/paddr: implement damon_folio_mkold()mm/damon/paddr.c+16 -110 replies
3/4mm/damon: add DAMOS filter type YOUNGinclude/linux/damon.h mm/damon/sysfs-schemes.c+3 -00 replies
4/4mm/damon/paddr: support DAMOS filter type YOUNGmm/damon/paddr.c+5 -00 replies

Reviews trailers per patch

None of the 4 patches has a Reviewed-by or Acked-by.

PatchHonggyu Kim
SeriesT-b
1/4
2/4
3/4
4/4

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v2 thread

Cover letter [RFC PATCH v2 0/4] mm/damon: add a DAMOS filter type for page granularity access recheck

Changes from RFC v1
(https://lore.kernel.org/r/[email protected])
- Rename __damon_pa_young() to damon_folio_young_one()
- Mark the folio as old from the filter for the next check

DAMON allows users to specify desired ranges of overhead and accuracy of the monitoring, and do its best effort to make most lightweight and accurate results. A recent discussion for tiered memory management support from DAMON[1] revealed that the best effort accuracy may not suffice in some use cases, while increasing the minimum accuracy can incur too high overhead. The discussion further concluded finding memory regions of specific access pattern via DAMON first, and then double checking the access of the region again in finer granularity could help increasing the accuracy while keeping the low overhead.

Add a new type of DAMOS filter, namely YOUNG for such a case. Like anon and memcg, the type of filter is applied to each page of the memory region of DAMOS target memory region, and check if the page is accessed since the last check. Because this is a filter type that applied in page granularity, the support depends on DAMON operations set. Because there are expected usages of this filter for physical address space based DAMOS usage[1], implement the support for only DAMON operations set for the physical address space, paddr.

[1] https://lore.kernel.org/r/[email protected]

SeongJae Park (4):
mm/damon/paddr: implement damon_folio_young()
mm/damon/paddr: implement damon_folio_mkold()
mm/damon: add DAMOS filter type YOUNG
mm/damon/paddr: support DAMOS filter type YOUNG

 include/linux/damon.h    |  2 ++
 mm/damon/paddr.c         | 64 +++++++++++++++++++++++++---------------
 mm/damon/sysfs-schemes.c |  1 +
 3 files changed, 43 insertions(+), 24 deletions(-)

base-commit: 13043cde46a19e72d37965b67b74e564623f65e7

Signature · 1 line
2.39.2