From: Andrew Morton <akpm@linux-foundation.org>
To: Christoph Lameter <clameter@sgi.com>
Cc: linux-mm@kvack.org
Subject: Re: SLUB: Define functions for cpu slab handling instead of using PageActive
Date: Mon, 14 May 2007 21:54:21 -0700 [thread overview]
Message-ID: <20070514215421.d2136057.akpm@linux-foundation.org> (raw)
In-Reply-To: <Pine.LNX.4.64.0705141959060.27789@schroedinger.engr.sgi.com>
On Mon, 14 May 2007 20:00:07 -0700 (PDT) Christoph Lameter <clameter@sgi.com> wrote:
> Use inline functions to access the per cpu bit. Intoduce the notion of
> "freezing" a slab to make things more understandable.
>
> ...
>
> +static inline void ClearSlabFrozen(struct page *page)
> +{
> + __ClearPageActive(page);
> +}
Non-atomic.
> - ClearPageActive(page);
Atomic.
A substitution like this can lead to quite revoltingly subtle bugs and needs
lots of justfication.
I'll switch this back to the atomic version. If you're really sure about
this micro-optimisation then let's do it as a standalone patch. One which
adds a comment explaining why it is safe, and under which circumstances it
will become unsafe, etc.
--
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:"dont@kvack.org"> email@kvack.org </a>
next prev parent reply other threads:[~2007-05-15 4:54 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-05-15 3:00 SLUB: Define functions for cpu slab handling instead of using PageActive Christoph Lameter
2007-05-15 4:54 ` Andrew Morton [this message]
2007-05-15 17:07 ` Christoph Lameter
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=20070514215421.d2136057.akpm@linux-foundation.org \
--to=akpm@linux-foundation.org \
--cc=clameter@sgi.com \
--cc=linux-mm@kvack.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.