From: Eric Sandeen <sandeen@sgi.com>
To: Christoph Hellwig <hch@infradead.org>
Cc: linux-kernel@vger.kernel.org, torvalds@transmeta.com,
marcelo@conectiva.com.br
Subject: Re: [PATCH] (repost) kmem_cache_zalloc
Date: 25 Apr 2002 15:33:21 -0500 [thread overview]
Message-ID: <1019766801.1939.68.camel@stout.americas.sgi.com> (raw)
In-Reply-To: <20020425094143.A17406@infradead.org>
Hi Christoph -
On Thu, 2002-04-25 at 03:41, Christoph Hellwig wrote:
> I don't think kmem_cache_zalloc is a good idea. The idea behind the slab
> cache is to allow object reuse by storing constructed objects in the
> caches, and a memset directly after the alloc destroys the object state.
> A kmen_zalloc/kzalloc might make more sense.
The constructor is one part of it, but what about more efficient memory
use? If we let things fall into the default power-of-two caches, we'd
waste quite a lot of memory.
See http://oss.sgi.com/~sandeen/slabinfo.html for example.
On this machine we'd use 30% more memory by using kmem_alloc vs
kmem_cache_alloc.
-Eric
--
Eric Sandeen XFS for Linux http://oss.sgi.com/projects/xfs
sandeen@sgi.com SGI, Inc.
next prev parent reply other threads:[~2002-04-25 20:33 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-04-24 21:07 Eric Sandeen
2002-04-25 7:26 ` arjan
2002-04-25 8:41 ` Christoph Hellwig
2002-04-25 20:33 ` Eric Sandeen [this message]
2002-04-27 20:11 ` Alan Cox
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=1019766801.1939.68.camel@stout.americas.sgi.com \
--to=sandeen@sgi.com \
--cc=hch@infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=marcelo@conectiva.com.br \
--cc=torvalds@transmeta.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
all inboxes | Powered by JetHome®