linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
* [RFC v2 0/4] Implement Data Access Monitoring-based Memory Operation Schemes
@ 2020-02-18  8:53 SeongJae Park
  2020-02-18  8:53 ` [RFC v2 1/4] mm/madvise: Export madvise_common() to mm internal code SeongJae Park
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: SeongJae Park @ 2020-02-18  8:53 UTC (permalink / raw)
  To: akpm
  Cc: SeongJae Park, acme, alexander.shishkin, amit, brendan.d.gregg,
	brendanhiggins, cai, colin.king, corbet, dwmw, jolsa, kirill,
	mark.rutland, mgorman, minchan, mingo, namhyung, peterz, rdunlap,
	rostedt, shuah, sj38.park, vdavydov.dev, linux-mm, linux-doc,
	linux-kernel

From: SeongJae Park <sjpark@amazon.de>

DAMON[1] can be used as a primitive for data access awared memory management
optimizations.  That said, users who want such optimizations should run DAMON,
read the monitoring results, analyze it, plan a new memory management scheme,
and apply the new scheme by themselves.  Such efforts will be inevitable for
some complicated optimizations.

However, in many other cases, the users would just want the system to apply an
memory management action to a memory region of a specific size having a
specific access frequency for a specific time.  For example, "page out a memory
region larger than 100 MiB keeping only rare accesses more than 10 minutes", or
"Use THP for a memory region larger than 2 MiB maintaing frequent accesses for
more than 5 seconds".

This RFC patchset makes DAMON to handle such data access monitoring-based
operation schemes.  With this change, users can do the data access awared
optimizations by simply specifying their schemes to DAMON.


Sequence Of Patches
===================

The patches are based on the v5.5 plus v5 DAMON patchset[1] and Minchan's
``madvise()`` factor-out patch[2].  Minchan's patch was necessary for reuse of
``madvise()`` code in DAMON.  You can also clone the complete git tree:

    $ git clone git://github.com/sjp38/linux -b damos/rfc/v2

The web is also available:
https://github.com/sjp38/linux/releases/tag/damos/rfc/v2

The first patch allows DAMON to reuse ``madvise()`` code for the actions.  The
second patch accounts age of each region.  Third patch implements the handling
of the schemes in DAMON and exports a kernel space programming interface for
it.  Finally, the fourth patch implements a debugfs interface for privileged
people and programs.

[1] https://lore.kernel.org/linux-mm/20200217103110.30817-1-sjpark@amazon.com/
[2] https://lore.kernel.org/linux-mm/20200128001641.5086-2-minchan@kernel.org/


Patch History
=============

Changes from RFC v1
(https://lore.kernel.org/linux-mm/20200210150921.32482-1-sjpark@amazon.com/)
 - Properly adjust age accounting related properties after splitting, merging,
   and action applying

SeongJae Park (4):
  mm/madvise: Export madvise_common() to mm internal code
  mm/damon: Account age of target regions
  mm/damon: Implement data access monitoring-based operation schemes
  mm/damon/schemes: Implement a debugfs interface

 include/linux/damon.h |  29 ++++
 mm/damon.c            | 360 +++++++++++++++++++++++++++++++++++++++++-
 mm/internal.h         |   4 +
 mm/madvise.c          |   3 +-
 4 files changed, 388 insertions(+), 8 deletions(-)

-- 
2.17.1



^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2020-02-18  8:54 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-02-18  8:53 [RFC v2 0/4] Implement Data Access Monitoring-based Memory Operation Schemes SeongJae Park
2020-02-18  8:53 ` [RFC v2 1/4] mm/madvise: Export madvise_common() to mm internal code SeongJae Park
2020-02-18  8:53 ` [RFC v2 2/4] mm/damon: Account age of target regions SeongJae Park
2020-02-18  8:53 ` [RFC v2 3/4] mm/damon: Implement data access monitoring-based operation schemes SeongJae Park
2020-02-18  8:53 ` [RFC v2 4/4] mm/damon/schemes: Implement a debugfs interface SeongJae Park

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).