[PATCH v2 0/2] task_mmu: Add user-space support for resetting mm->hiwater_rss (peak RSS)

From: Petr Cermak
Date: Wed Jan 07 2015 - 12:07:32 EST


Being able to reset mm->hiwater_rss (resident set size high water mark) from
user space would enable fine grained iterative memory profiling. I propose a
very short patch for doing so.

The driving use-case for this would be getting the peak RSS value, which can be
retrieved from the VmHWM field in /proc/pid/status, per benchmark iteration or
test scenario.

Changelog:

v2:
- clarify behaviour in documentation as suggesed by Andrew Morton
<akpm@xxxxxxxxxxxxxxxxxxxx>
- fix a declaration-after-statement warning in fs/proc/task_mmu.c

v1: https://lkml.org/lkml/2014/12/10/312

Petr Cermak (2):
task_mmu: Reduce excessive indentation in clear_refs_write
task_mmu: Add user-space support for resetting mm->hiwater_rss (peak RSS)

Documentation/filesystems/proc.txt | 3 +
fs/proc/task_mmu.c | 115 +++++++++++++++++++++----------------
include/linux/mm.h | 5 ++
3 files changed, 74 insertions(+), 49 deletions(-)

--
2.2.0.rc0.207.ga3a616c

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/