Re: [PATCH 1/3] mm: introduce NR_INDIRECTLY_RECLAIMABLE_BYTES

2018-04-25 Thread Roman Gushchin
On Wed, Apr 25, 2018 at 07:02:42PM +0200, Vlastimil Babka wrote: > On 04/25/2018 06:48 PM, Roman Gushchin wrote: > > On Wed, Apr 25, 2018 at 05:47:26PM +0200, Vlastimil Babka wrote: > >> On 04/25/2018 02:52 PM, Roman Gushchin wrote: > >>> On Wed, Apr 25, 2018 at 09:19:29AM +0530, Vijayanand Jitta w

Re: [PATCH 1/3] mm: introduce NR_INDIRECTLY_RECLAIMABLE_BYTES

2018-04-25 Thread Vlastimil Babka
On 04/25/2018 06:48 PM, Roman Gushchin wrote: > On Wed, Apr 25, 2018 at 05:47:26PM +0200, Vlastimil Babka wrote: >> On 04/25/2018 02:52 PM, Roman Gushchin wrote: >>> On Wed, Apr 25, 2018 at 09:19:29AM +0530, Vijayanand Jitta wrote: Idk, I don't like the idea of adding a counter outside of

Re: [PATCH 1/3] mm: introduce NR_INDIRECTLY_RECLAIMABLE_BYTES

2018-04-25 Thread Vlastimil Babka
On 04/25/2018 05:55 PM, Matthew Wilcox wrote: > On Fri, Apr 13, 2018 at 05:43:39PM +0530, vinayak menon wrote: >> One such case I have encountered is that of the ION page pool. The page pool >> registers a shrinker. When not in any memory pressure page pool can go high >> and thus cause an mmap to

Re: [PATCH 1/3] mm: introduce NR_INDIRECTLY_RECLAIMABLE_BYTES

2018-04-25 Thread Roman Gushchin
On Wed, Apr 25, 2018 at 05:47:26PM +0200, Vlastimil Babka wrote: > On 04/25/2018 02:52 PM, Roman Gushchin wrote: > > On Wed, Apr 25, 2018 at 09:19:29AM +0530, Vijayanand Jitta wrote: > >> Idk, I don't like the idea of adding a counter outside of the vm > >> counters > >> infrastructure

Re: [PATCH 1/3] mm: introduce NR_INDIRECTLY_RECLAIMABLE_BYTES

2018-04-25 Thread Vlastimil Babka
On 04/25/2018 02:52 PM, Roman Gushchin wrote: > On Wed, Apr 25, 2018 at 09:19:29AM +0530, Vijayanand Jitta wrote: >> Idk, I don't like the idea of adding a counter outside of the vm counters >> infrastructure, and I definitely wouldn't touch the exposed >> nr_slab_reclaimable and nr_sla

Re: [PATCH 1/3] mm: introduce NR_INDIRECTLY_RECLAIMABLE_BYTES

2018-04-25 Thread Matthew Wilcox
On Fri, Apr 13, 2018 at 05:43:39PM +0530, vinayak menon wrote: > One such case I have encountered is that of the ION page pool. The page pool > registers a shrinker. When not in any memory pressure page pool can go high > and thus cause an mmap to fail when OVERCOMMIT_GUESS is set. I can send > a p

Re: [PATCH 1/3] mm: introduce NR_INDIRECTLY_RECLAIMABLE_BYTES

2018-04-25 Thread Roman Gushchin
On Wed, Apr 25, 2018 at 09:19:29AM +0530, Vijayanand Jitta wrote: > Idk, I don't like the idea of adding a counter outside of the vm counters > infrastructure, and I definitely wouldn't touch the exposed > nr_slab_reclaimable and nr_slab_unreclaimable fields. > >>> > >>> We would be

Re: [PATCH 1/3] mm: introduce NR_INDIRECTLY_RECLAIMABLE_BYTES

2018-04-24 Thread Vijayanand Jitta
On 4/13/2018 5:43 PM, vinayak menon wrote: > On Thu, Apr 12, 2018 at 8:27 PM, Roman Gushchin wrote: >> On Thu, Apr 12, 2018 at 08:52:52AM +0200, Vlastimil Babka wrote: >>> On 04/11/2018 03:56 PM, Roman Gushchin wrote: On Wed, Apr 11, 2018 at 03:16:08PM +0200, Vlastimil Babka wrote: > [+

Re: [PATCH 1/3] mm: introduce NR_INDIRECTLY_RECLAIMABLE_BYTES

2018-04-13 Thread vinayak menon
On Thu, Apr 12, 2018 at 8:27 PM, Roman Gushchin wrote: > On Thu, Apr 12, 2018 at 08:52:52AM +0200, Vlastimil Babka wrote: >> On 04/11/2018 03:56 PM, Roman Gushchin wrote: >> > On Wed, Apr 11, 2018 at 03:16:08PM +0200, Vlastimil Babka wrote: >> >> [+CC linux-api] >> >> >> >> On 03/05/2018 02:37 PM,

Re: [PATCH 1/3] mm: introduce NR_INDIRECTLY_RECLAIMABLE_BYTES

2018-04-13 Thread Michal Hocko
On Thu 12-04-18 15:57:03, Roman Gushchin wrote: > On Thu, Apr 12, 2018 at 08:52:52AM +0200, Vlastimil Babka wrote: [...] > > We would be just making the reported values more precise wrt reality. > > It depends on if we believe that only slab memory can be reclaimable > or not. If yes, this is true

Re: [PATCH 1/3] mm: introduce NR_INDIRECTLY_RECLAIMABLE_BYTES

2018-04-12 Thread Roman Gushchin
On Thu, Apr 12, 2018 at 08:52:52AM +0200, Vlastimil Babka wrote: > On 04/11/2018 03:56 PM, Roman Gushchin wrote: > > On Wed, Apr 11, 2018 at 03:16:08PM +0200, Vlastimil Babka wrote: > >> [+CC linux-api] > >> > >> On 03/05/2018 02:37 PM, Roman Gushchin wrote: > >>> This patch introduces a concept of

Re: [PATCH 1/3] mm: introduce NR_INDIRECTLY_RECLAIMABLE_BYTES

2018-04-12 Thread Michal Hocko
On Thu 12-04-18 15:38:33, Roman Gushchin wrote: > On Thu, Apr 12, 2018 at 01:52:17PM +0200, Michal Hocko wrote: > > On Thu 12-04-18 08:52:52, Vlastimil Babka wrote: > > > On 04/11/2018 03:56 PM, Roman Gushchin wrote: > > > > On Wed, Apr 11, 2018 at 03:16:08PM +0200, Vlastimil Babka wrote: > > [...]

Re: [PATCH 1/3] mm: introduce NR_INDIRECTLY_RECLAIMABLE_BYTES

2018-04-12 Thread Roman Gushchin
On Thu, Apr 12, 2018 at 01:52:17PM +0200, Michal Hocko wrote: > On Thu 12-04-18 08:52:52, Vlastimil Babka wrote: > > On 04/11/2018 03:56 PM, Roman Gushchin wrote: > > > On Wed, Apr 11, 2018 at 03:16:08PM +0200, Vlastimil Babka wrote: > [...] > > >> With that in mind, can we at least for now put the

Re: [PATCH 1/3] mm: introduce NR_INDIRECTLY_RECLAIMABLE_BYTES

2018-04-12 Thread Michal Hocko
On Thu 12-04-18 08:52:52, Vlastimil Babka wrote: > On 04/11/2018 03:56 PM, Roman Gushchin wrote: > > On Wed, Apr 11, 2018 at 03:16:08PM +0200, Vlastimil Babka wrote: [...] > >> With that in mind, can we at least for now put the (manually maintained) > >> byte counter in a variable that's not direct

Re: [PATCH 1/3] mm: introduce NR_INDIRECTLY_RECLAIMABLE_BYTES

2018-04-11 Thread Vlastimil Babka
On 04/11/2018 03:56 PM, Roman Gushchin wrote: > On Wed, Apr 11, 2018 at 03:16:08PM +0200, Vlastimil Babka wrote: >> [+CC linux-api] >> >> On 03/05/2018 02:37 PM, Roman Gushchin wrote: >>> This patch introduces a concept of indirectly reclaimable memory >>> and adds the corresponding memory counter

Re: [PATCH 1/3] mm: introduce NR_INDIRECTLY_RECLAIMABLE_BYTES

2018-04-11 Thread Roman Gushchin
On Wed, Apr 11, 2018 at 03:16:08PM +0200, Vlastimil Babka wrote: > [+CC linux-api] > > On 03/05/2018 02:37 PM, Roman Gushchin wrote: > > This patch introduces a concept of indirectly reclaimable memory > > and adds the corresponding memory counter and /proc/vmstat item. > > > > Indirectly reclaim

Re: [PATCH 1/3] mm: introduce NR_INDIRECTLY_RECLAIMABLE_BYTES

2018-04-11 Thread Vlastimil Babka
[+CC linux-api] On 03/05/2018 02:37 PM, Roman Gushchin wrote: > This patch introduces a concept of indirectly reclaimable memory > and adds the corresponding memory counter and /proc/vmstat item. > > Indirectly reclaimable memory is any sort of memory, used by > the kernel (except of reclaimable

[PATCH 1/3] mm: introduce NR_INDIRECTLY_RECLAIMABLE_BYTES

2018-03-05 Thread Roman Gushchin
This patch introduces a concept of indirectly reclaimable memory and adds the corresponding memory counter and /proc/vmstat item. Indirectly reclaimable memory is any sort of memory, used by the kernel (except of reclaimable slabs), which is actually reclaimable, i.e. will be released under memory