public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Rohit Seth <rohit.seth@intel.com>
To: "Martin J. Bligh" <mbligh@mbligh.org>
Cc: Andrew Morton <akpm@osdl.org>, Mattia Dongili <malattia@linux.it>,
	linux-kernel@vger.kernel.org
Subject: Re: 2.6.14-rc2-mm1
Date: Tue, 27 Sep 2005 14:51:59 -0700	[thread overview]
Message-ID: <1127857919.7258.13.camel@akash.sc.intel.com> (raw)
In-Reply-To: <970900000.1127855894@flay>

On Tue, 2005-09-27 at 14:18 -0700, Martin J. Bligh wrote:
> >> > --- linux-2.6.13.old/mm/page_alloc.c  2005-09-26 10:57:07.000000000
> >> -0700 
> >> > +++ linux-2.6.13.work/mm/page_alloc.c 2005-09-26 10:47:57.000000000
> >> -0700 
> >> > @@ -1749,7 +1749,7 @@ 
> >> >       pcp = &p->pcp[1];               /* cold*/ 
> >> >       pcp->count = 0; 
> >> >       pcp->low = 0; 
> >> > -     pcp->high = 2 * batch; 
> >> > +     pcp->high = batch / 2; 
> >> >       pcp->batch = max(1UL, batch/2); 
> >> >       INIT_LIST_HEAD(&pcp->list); 
> >> >  } 
> >> > -
> >> 
> >> I don't understand. How can you set the high watermark at half the
> >> batch size? Makes no sense to me.
> >> 
> > 
> > The batch size for the cold pcp list is getting initialized to batch/2
> > in the code snip above.  So, this change is setting the high water mark
> > for cold list to same as pcp's batch number.
> 
> I must be being particularly dense today ... but:
> 
>  pcp->high = batch / 2; 
> 
> Looks like half the batch size to me, not the same? 

pcp->batch = max(1UL, batch/2); is the line of code that is setting the
batch value for the cold pcp list.  batch is just a number that we
counted based on some parameters earlier.


> 
> >> And can you give a stricter definiton of what you mean by "low memory 
> >> conditions"? I agree we ought to empty the lists before going OOM or 
> >> anything, but not at the slightest feather of pressure ... answer lies
> >> somewhere inbetween ... but where?
> >> 
> > 
> > In the specific case of dump information that Mattia sent earlier, there
> > is only 4M of free mem available at the time the order 1 request is
> > failing.  
> > 
> > In general, I think if a specific higher order ( > 0) request fails that
> > has GFP_KERNEL set then at least we should drain the pcps.
> 
> Mmmm. so every time we fork a process with 8K stacks, or allocate a frame
> for jumbo ethernet, or NFS, you want to drain the lists? that seems to
> wholly defeat the purpose.
> 

Not every time there is a request for higher order pages.  That surely
will defeat the purpose of pcps.  But my suggestion is only to drain
when the the global pool is not able to service the request.  In the
pathological case where the higher order and zero order requests are
alternating you could have thrashing in terms of pages moving to pcp for
them to move back to global list.

> Could you elaborate on what the benefits were from this change in the
> first place? Some page colouring thing on ia64? It seems to have way more
> downside than upside to me.

The original change was to try to allocate a higher order page to
service a batch size bulk request.  This was with the hope that better
physical contiguity will spread the data better across big caches.

-rohit


  reply	other threads:[~2005-09-27 21:44 UTC|newest]

Thread overview: 44+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-09-22  5:28 2.6.14-rc2-mm1 Andrew Morton
2005-09-22  6:35 ` 2.6.14-rc2-mm1 Joel Becker
2005-09-22  6:46 ` 2.6.14-rc2-mm1 Reuben Farrelly
2005-09-22  7:03   ` 2.6.14-rc2-mm1 Andrew Morton
2005-09-22 18:59 ` 2.6.14-rc2-mm1 Martin J. Bligh
2005-09-22 19:52   ` 2.6.14-rc2-mm1 Andrew Morton
2005-09-22 20:14     ` 2.6.14-rc2-mm1 Martin J. Bligh
2005-09-23  0:28       ` 2.6.14-rc2-mm1 Martin J. Bligh
2005-09-22 22:28     ` 2.6.14-rc2-mm1 - ide problems ? Badari Pulavarty
2005-09-22 23:39       ` Andrew Morton
2005-09-22 19:50 ` tty update speed regression (was: 2.6.14-rc2-mm1) Alexey Dobriyan
2005-09-22 21:49   ` Alexey Dobriyan
2005-09-23  0:08     ` Nishanth Aravamudan
2005-09-23 17:12       ` Nish Aravamudan
2005-09-23 18:42         ` Alexey Dobriyan
2005-09-23 19:07           ` Nishanth Aravamudan
2005-09-23 19:42             ` Alexey Dobriyan
2005-09-23 21:32               ` Nishanth Aravamudan
2005-09-24 17:43 ` 2.6.14-rc2-mm1 Mattia Dongili
2005-09-24 17:58 ` 2.6.14-rc2-mm1 Mattia Dongili
2005-09-24 18:23   ` 2.6.14-rc2-mm1 Andrew Morton
2005-09-26 19:33     ` 2.6.14-rc2-mm1 Seth, Rohit
2005-09-27 18:57       ` 2.6.14-rc2-mm1 Martin J. Bligh
2005-09-27 20:05         ` 2.6.14-rc2-mm1 Rohit Seth
2005-09-27 21:18           ` 2.6.14-rc2-mm1 Martin J. Bligh
2005-09-27 21:51             ` Rohit Seth [this message]
2005-09-27 21:59               ` 2.6.14-rc2-mm1 Martin J. Bligh
2005-09-27 22:49                 ` 2.6.14-rc2-mm1 Rohit Seth
2005-09-27 22:49                   ` 2.6.14-rc2-mm1 Martin J. Bligh
2005-09-27 23:16                     ` 2.6.14-rc2-mm1 Rohit Seth
2005-09-27  7:13 ` 2.6.14-rc2-mm1 (Oops, possibly Netfilter related?) Reuben Farrelly
2005-09-27  7:44   ` Andrew Morton
2005-09-27 18:59     ` Martin J. Bligh
2005-10-02 17:13       ` Paul Jackson
2005-10-02 21:31         ` Martin J. Bligh
2005-10-03 17:20           ` Rohit Seth
2005-10-03 17:56             ` Martin J. Bligh
  -- strict thread matches above, loose matches on Subject: below --
2005-09-25 22:00 2.6.14-rc2-mm1 Paul Blazejowski
2005-09-25 23:44 ` 2.6.14-rc2-mm1 Andrew Morton
2005-09-26  4:32   ` 2.6.14-rc2-mm1 Carlo Calica
2005-09-28  4:56   ` 2.6.14-rc2-mm1 Paul Blazejowski
2005-09-28 19:07     ` 2.6.14-rc2-mm1 Carlo Calica
2005-09-26  7:14 ` 2.6.14-rc2-mm1 Tim Schmielau
2005-09-28  5:01   ` 2.6.14-rc2-mm1 Paul Blazejowski

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1127857919.7258.13.camel@akash.sc.intel.com \
    --to=rohit.seth@intel.com \
    --cc=akpm@osdl.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=malattia@linux.it \
    --cc=mbligh@mbligh.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox