From: Christoph Lameter <clameter@engr.sgi.com>
To: Andrew Morton <akpm@osdl.org>
Cc: Marcelo Tosatti <marcelo.tosatti@cyclades.com>,
manfred@colorfullife.com, linux-mm@kvack.org, dgc@sgi.com,
dipankar@in.ibm.com, mbligh@mbligh.org, arjanv@redhat.com
Subject: Re: [PATCH] per-page SLAB freeing (only dcache for now)
Date: Sat, 22 Oct 2005 10:08:52 -0700 (PDT) [thread overview]
Message-ID: <Pine.LNX.4.62.0510221002020.27511@schroedinger.engr.sgi.com> (raw)
In-Reply-To: <20051021233111.58706a2e.akpm@osdl.org>
On Fri, 21 Oct 2005, Andrew Morton wrote:
> Marcelo Tosatti <marcelo.tosatti@cyclades.com> wrote:
> >
> > ...
> > +unsigned long long slab_free_status(kmem_cache_t *cachep, struct slab *slabp)
> > +{
> > + unsigned long long bitmap = 0;
> > + int i;
> > +
> > + if (cachep->num > sizeof(unsigned long long)*8)
> > + BUG();
> > +
> > + spin_lock_irq(&cachep->spinlock);
> > + for(i=0; i < cachep->num ; i++) {
> > + if (slab_bufctl(slabp)[i] == BUFCTL_INUSE)
> > + set_bit(i, (unsigned long *)&bitmap);
> > + }
> > + spin_unlock_irq(&cachep->spinlock);
> > +
> > + return bitmap;
> > +}
>
> What if there are more than 64 objects per page?
The current worst case is 16k pagesize (IA64) and one cacheline sized
objects (128 bytes) (hmm.. could even be smaller if the arch does
overrride SLAB_HWCACHE_ALIGN) yielding a maximum of 128 entries per page.
There are been versions of Linux for IA64 out there with 64k pagesize on
IA64 and there is the possibility that we need to switch to 64k as a
standard next year when we may have single OS images running with more
than 16TB Ram.
--
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:[~2005-10-22 17:08 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-09-30 19:37 Marcelo
2005-10-01 2:46 ` Christoph Lameter
2005-10-01 21:52 ` Marcelo
2005-10-03 15:24 ` Christoph Lameter
2005-10-03 20:37 ` Manfred Spraul
2005-10-03 22:17 ` Marcelo Tosatti
2005-10-04 17:04 ` Manfred Spraul
2005-10-06 16:01 ` Marcelo Tosatti
2005-10-22 1:30 ` Marcelo Tosatti
2005-10-22 6:31 ` Andrew Morton
2005-10-22 9:21 ` Arjan van de Ven
2005-10-22 17:08 ` Christoph Lameter [this message]
2005-10-22 17:13 ` ia64 page size (was Re: [PATCH] per-page SLAB freeing (only dcache for now)) Arjan van de Ven
2005-10-22 18:16 ` [PATCH] per-page SLAB freeing (only dcache for now) Manfred Spraul
2005-10-23 18:41 ` Marcelo Tosatti
2005-10-23 16:30 ` Marcelo Tosatti
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=Pine.LNX.4.62.0510221002020.27511@schroedinger.engr.sgi.com \
--to=clameter@engr.sgi.com \
--cc=akpm@osdl.org \
--cc=arjanv@redhat.com \
--cc=dgc@sgi.com \
--cc=dipankar@in.ibm.com \
--cc=linux-mm@kvack.org \
--cc=manfred@colorfullife.com \
--cc=marcelo.tosatti@cyclades.com \
--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