Re: [PATCH 00/19 V2] mm: memcontrol: charge swapin pages on instantiation

2020-05-14 Thread Balbir Singh
On 13/5/20 10:35 pm, Johannes Weiner wrote: > As a result, the memcg gets a breakdown for memory.stat without having > to have private knowledge of what a page cache page is - how to test > it, when it's safe to test it, whether there can be huge pages in the > page cache, etc. pp. Memcg can foc

Re: [PATCH 00/19 V2] mm: memcontrol: charge swapin pages on instantiation

2020-05-13 Thread Johannes Weiner
Hello Balbir! On Wed, May 13, 2020 at 11:30:32AM +, Balbir Singh wrote: > On Fri, May 08, 2020 at 02:30:47PM -0400, Johannes Weiner wrote: > > To eliminate the page->mapping dependency, memcg needs to ditch its > > private page type counters (MEMCG_CACHE, MEMCG_RSS, NR_SHMEM) in favor > > of t

Re: [PATCH 00/19 V2] mm: memcontrol: charge swapin pages on instantiation

2020-05-13 Thread Balbir Singh
On Fri, May 08, 2020 at 02:30:47PM -0400, Johannes Weiner wrote: > This patch series reworks memcg to charge swapin pages directly at > swapin time, rather than at fault time, which may be much later, or > not happen at all. > > Changes in version 2: > - prevent double charges on pre-allocated hug

[PATCH 00/19 V2] mm: memcontrol: charge swapin pages on instantiation

2020-05-08 Thread Johannes Weiner
This patch series reworks memcg to charge swapin pages directly at swapin time, rather than at fault time, which may be much later, or not happen at all. Changes in version 2: - prevent double charges on pre-allocated hugepages in khugepaged - leave shmem swapcache when charging fails to avoid dou