lkml.org 
[lkml]   [2015]   [Nov]   [25]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH] mm/vmstat: retrieve more accurate vmstat value
From
Date
On 11/25/2015 01:00 PM, Michal Hocko wrote:
> On Tue 24-11-15 15:22:03, Joonsoo Kim wrote:
>> When I tested compaction in low memory condition, I found that
>> my benchmark is stuck in congestion_wait() at shrink_inactive_list().
>> This stuck last for 1 sec and after then it can escape. More investigation
>> shows that it is due to stale vmstat value. vmstat is updated every 1 sec
>> so it is stuck for 1 sec.
>
> Wouldn't it be sufficient to use zone_page_state_snapshot in
> too_many_isolated?

That sounds better than the ad-hoc half-solution, yeah.
I don't know how performance sensitive the callers are, but maybe it could do a
non-snapshot check first, and only repeat with _snapshot when it's about to wait
(the result is true), just to make sure?

OTOH, how big issue is this? I suspect the system has been genuinely
too_many_isolated(), or very close, in order to hit the condition in the first
place, and the inaccuracy just delays the recovery a bit?



\
 
 \ /
  Last update: 2015-11-25 15:01    [W:0.593 / U:0.116 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site