Re: [patch 3/3] mm: page_alloc: fair zone allocator policy

2013-08-02 Thread Minchan Kim
On Fri, Aug 02, 2013 at 02:22:08AM -0400, Johannes Weiner wrote: > On Thu, Aug 01, 2013 at 11:56:36AM +0900, Minchan Kim wrote: > > Hi Hannes, > > > > On Fri, Jul 19, 2013 at 04:55:25PM -0400, Johannes Weiner wrote: > > > Each zone that holds userspace pages of one workload must be aged at a > > >

Re: [patch 3/3] mm: page_alloc: fair zone allocator policy

2013-08-01 Thread Johannes Weiner
On Thu, Aug 01, 2013 at 11:56:36AM +0900, Minchan Kim wrote: > Hi Hannes, > > On Fri, Jul 19, 2013 at 04:55:25PM -0400, Johannes Weiner wrote: > > Each zone that holds userspace pages of one workload must be aged at a > > speed proportional to the zone size. Otherwise, the time an > > individual

Re: [patch 3/3] mm: page_alloc: fair zone allocator policy

2013-08-01 Thread Andrea Arcangeli
On Thu, Aug 01, 2013 at 03:58:23PM -0400, Johannes Weiner wrote: > But we might be able to get away with a small error. The idea is that there's a small error anyway, because multiple CPUs can reset it at the same time, while another CPU is decreasing it, so the decrease sometime may get lost rega

Re: [patch 3/3] mm: page_alloc: fair zone allocator policy

2013-08-01 Thread Johannes Weiner
On Thu, Aug 01, 2013 at 05:51:11PM +0200, Andrea Arcangeli wrote: > On Thu, Aug 01, 2013 at 12:31:34AM -0400, Rik van Riel wrote: > > On 07/31/2013 10:56 PM, Minchan Kim wrote: > > > > > Yes, it's not really slow path because it could return to normal status > > > without calling significant slow

Re: [patch 3/3] mm: page_alloc: fair zone allocator policy

2013-08-01 Thread Andrea Arcangeli
On Thu, Aug 01, 2013 at 12:31:34AM -0400, Rik van Riel wrote: > On 07/31/2013 10:56 PM, Minchan Kim wrote: > > > Yes, it's not really slow path because it could return to normal status > > without calling significant slow functions by reset batchcount of > > prepare_slowpath. > > > > I think it's

Re: [patch 3/3] mm: page_alloc: fair zone allocator policy

2013-07-31 Thread Rik van Riel
On 07/31/2013 10:56 PM, Minchan Kim wrote: Yes, it's not really slow path because it could return to normal status without calling significant slow functions by reset batchcount of prepare_slowpath. I think it's tradeoff and I am biased your approach although we would lose a little performance

Re: [patch 3/3] mm: page_alloc: fair zone allocator policy

2013-07-31 Thread Minchan Kim
Hi Hannes, On Fri, Jul 19, 2013 at 04:55:25PM -0400, Johannes Weiner wrote: > Each zone that holds userspace pages of one workload must be aged at a > speed proportional to the zone size. Otherwise, the time an > individual page gets to stay in memory depends on the zone it happened > to be alloc

Re: [patch 3/3] mm: page_alloc: fair zone allocator policy

2013-07-29 Thread Johannes Weiner
On Mon, Jul 29, 2013 at 07:48:21PM +0200, Andrea Arcangeli wrote: > Hi Johannes, > > On Fri, Jul 19, 2013 at 04:55:25PM -0400, Johannes Weiner wrote: > > diff --git a/mm/page_alloc.c b/mm/page_alloc.c > > index af1d956b..d938b67 100644 > > --- a/mm/page_alloc.c > > +++ b/mm/page_alloc.c > > @@ -18

Re: [patch 3/3] mm: page_alloc: fair zone allocator policy

2013-07-29 Thread Andrea Arcangeli
Hi Johannes, On Fri, Jul 19, 2013 at 04:55:25PM -0400, Johannes Weiner wrote: > diff --git a/mm/page_alloc.c b/mm/page_alloc.c > index af1d956b..d938b67 100644 > --- a/mm/page_alloc.c > +++ b/mm/page_alloc.c > @@ -1879,6 +1879,14 @@ zonelist_scan: > if (alloc_flags & ALLOC_NO_WATERMA

Re: [patch 3/3] mm: page_alloc: fair zone allocator policy

2013-07-25 Thread Paul Bolle
On Thu, 2013-07-25 at 11:10 -0400, Johannes Weiner wrote: > [ I Cc'd Paul Bolle at pebo...@tiscali.nl as well, his English was > better from there ] Namespace collission! That's not me! Could my double perhaps use another name, like say, Paul Bollee? Or something even less confusing? Thanks!

Re: [patch 3/3] mm: page_alloc: fair zone allocator policy

2013-07-25 Thread Johannes Weiner
Hi Paul Bolle^W^W Sam Ben^W^W Hush Bensen^W^W Mtrr Patt^W^W Ric Mason^W^W Will Huck^W^W Simon Jeons^W^W Jaeguk Hanse^W^W Ni zhan Chen^W^W^W Wanpeng Li [ I Cc'd Paul Bolle at pebo...@tiscali.nl as well, his English was better from there ] On Thu, Jul 25, 2013 at 02:50:54PM +0800, Paul Bolle wrot

Re: [patch 3/3] mm: page_alloc: fair zone allocator policy

2013-07-24 Thread Paul Bolle
On 07/23/2013 04:21 AM, Rik van Riel wrote: On 07/19/2013 04:55 PM, Johannes Weiner wrote: @@ -1984,7 +1992,8 @@ this_zone_full: goto zonelist_scan; } -if (page) +if (page) { +atomic_sub(1U << order, &zone->alloc_batch); /* * page->pfmemallo

Re: [patch 3/3] mm: page_alloc: fair zone allocator policy

2013-07-22 Thread Rik van Riel
On 07/22/2013 05:04 PM, Johannes Weiner wrote: On Mon, Jul 22, 2013 at 04:21:07PM -0400, Rik van Riel wrote: On 07/19/2013 04:55 PM, Johannes Weiner wrote: @@ -1984,7 +1992,8 @@ this_zone_full: goto zonelist_scan; } - if (page) + if (page) { +

Re: [patch 3/3] mm: page_alloc: fair zone allocator policy

2013-07-22 Thread Johannes Weiner
On Mon, Jul 22, 2013 at 04:21:07PM -0400, Rik van Riel wrote: > On 07/19/2013 04:55 PM, Johannes Weiner wrote: > > >@@ -1984,7 +1992,8 @@ this_zone_full: > > goto zonelist_scan; > > } > > > >-if (page) > >+if (page) { > >+atomic_sub(1U << order, &zone->alloc_bat

Re: [patch 3/3] mm: page_alloc: fair zone allocator policy

2013-07-22 Thread Rik van Riel
On 07/19/2013 04:55 PM, Johannes Weiner wrote: @@ -1984,7 +1992,8 @@ this_zone_full: goto zonelist_scan; } - if (page) + if (page) { + atomic_sub(1U << order, &zone->alloc_batch); /* * page->pfmemalloc is set whe