diff options
| author | Martijn Coenen <maco@google.com> | 2016-02-17 10:48:40 +0100 |
|---|---|---|
| committer | Moyster <oysterized@gmail.com> | 2018-12-11 15:51:10 +0100 |
| commit | 88e64759a0643e835a6bf63cf2489d62d33f5a29 (patch) | |
| tree | 93664f1bc7cff2a0ba03be369f9824c615952b08 /scripts/markup_oops.pl | |
| parent | f99ca4b666d0f954405bc91265030af50a66f5c6 (diff) | |
mm: vmpressure: dynamic window sizing.
The window size used for calculating vm pressure events was
previously fixed at 512 pages. The window size has a big
impact on the rate of notifications sent off to userspace,
in particular when using the "low" level. On machines with
a lot of memory, the current value is likely excessive. On
the other hand, if the window size is too big, we might
delay memory pressure events for too long, especially at
critical levels of memory pressure.
This patch attempts to address that problem with two changes.
The first change is to calculate the window size
based on the machine size, quite similar to how the vm
watermarks are being calculated. This reduces the chance
of false positives at any pressure level. Using the machine
size only makes sense on the root cgroup though; for non-root
cgroups, their hard memory limit is used to calculate the
window size. If no hard memory limit is set, we fall back to
the default window size that was previously used.
The second change is based on an idea from Johannes Weiner, to
only report medium and low pressure levels for every
X windows that we scan. This reduces the frequency with
which we report low/medium pressure levels, but at the same
time will still report critical memory pressure immediately.
Change-Id: Ieffca055b2fb6aa27ae0179e0a588e6fcb173a61
Signed-off-by: Martijn Coenen <maco@google.com>
Diffstat (limited to 'scripts/markup_oops.pl')
0 files changed, 0 insertions, 0 deletions
