linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: Andrew Morton <akpm@osdl.org>
To: colpatch@us.ibm.com
Cc: linux-kernel@vger.kernel.org, linux-mm@kvack.org,
	mbligh@aracnet.com, jbarnes@sgi.com
Subject: Re: [RFC] Simplify node/zone portion of page->flags
Date: Sun, 23 Nov 2003 14:40:52 -0800	[thread overview]
Message-ID: <20031123144052.1f0d5071.akpm@osdl.org> (raw)
In-Reply-To: <3FBEB867.9080506@us.ibm.com>

Matthew Dobson <colpatch@us.ibm.com> wrote:
>
> Currently we keep track of a pages node & zone in the top 8 bits (on 
>  32-bit arches, 10 bits on 64-bit arches) of page->flags.  We typically 
>  do: node_num * MAX_NR_ZONES + zone_num = 'nodezone'.  It's non-trivial 
>  to break this 'nodezone' back into node and zone numbers.  This patch 
>  modifies the way we compute the index to be: (node_num << ZONE_SHIFT) | 
>  zone_num.  This makes it trivial to recover either the node or zone 
>  number with a simple bitshift.  There are many places in the kernel 
>  where we do things like: page_zone(page)->zone_pgdat->node_id to 
>  determine the node a page belongs to.  With this patch we save several 
>  pointer dereferences, and it boils down to shifting some bits.

This rather conflicts with the patch from Jesse which I have.  Can you guys
work that out and let me know when you're done?

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"aart@kvack.org"> aart@kvack.org </a>

  reply	other threads:[~2003-11-23 22:40 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-11-22  1:14 Matthew Dobson
2003-11-23 22:40 ` Andrew Morton [this message]
2003-11-23 22:49   ` Jesse Barnes
2003-11-24 23:31     ` Jesse Barnes

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=20031123144052.1f0d5071.akpm@osdl.org \
    --to=akpm@osdl.org \
    --cc=colpatch@us.ibm.com \
    --cc=jbarnes@sgi.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=mbligh@aracnet.com \
    /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