From: Dipankar Sarma <dipankar@in.ibm.com>
To: Manfred Spraul <manfred@colorfullife.com>
Cc: Andrew Morton <akpm@osdl.org>,
linux-kernel@vger.kernel.org, Hugh Dickins <hugh@veritas.com>
Subject: Re: Fw: two 2.6.13-rc3-mm3 oddities
Date: Mon, 8 Aug 2005 22:16:36 +0530 [thread overview]
Message-ID: <20050808164636.GA6153@in.ibm.com> (raw)
In-Reply-To: <42F788F8.1000001@colorfullife.com>
On Mon, Aug 08, 2005 at 06:31:52PM +0200, Manfred Spraul wrote:
> Dipankar Sarma wrote:
>
> >Hugh, could you please try this with the experimental patch below ?
> >Manfred, is it safe to decrement nr_files in file_free()
> >instead of the destructor ? I can't see any problem.
> >
> >
> >
> The ctor/dtor are only called when new objects are created, not on every
> kmem_cache_alloc/kmem_cache_free. Thus I would expect that the counter
> becomes negative on builds without CONFIG_DEBUG_SLAB.
> Thus increase in the ctor and decrease in file_free() is the wrong
> thing. If you want to move the decrease from the dtor to file_free, then
> you must move the increase, too.
> But: IIRC the counters were moved to the ctor/dtor for performance
> reasons, I'd guess mbligh ran into cache line trashing on the
> filp_count_lock spinlock with reaim or something like that.
Ah, so the whole idea was to inc/dec nr_files less often so
that we reduce contention on filp_count_lock, right ? This however
causes skews nr_files by the size of the slab array, AFAICS.
Since we check nr_files before we allocate files from slab, the
check seems inaccurate.
Anyway, I guess, I need to look at scaling the file counting
first.
Thanks
Dipankar
next prev parent reply other threads:[~2005-08-08 16:51 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20050803095644.78b58cb4.akpm@osdl.org>
2005-08-08 14:05 ` Fw: two 2.6.13-rc3-mm3 oddities Dipankar Sarma
2005-08-08 15:26 ` Hugh Dickins
2005-08-08 16:31 ` Manfred Spraul
2005-08-08 16:46 ` Dipankar Sarma [this message]
2005-08-08 17:25 ` Andrew Morton
2005-08-08 18:03 ` Dipankar Sarma
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=20050808164636.GA6153@in.ibm.com \
--to=dipankar@in.ibm.com \
--cc=akpm@osdl.org \
--cc=hugh@veritas.com \
--cc=linux-kernel@vger.kernel.org \
--cc=manfred@colorfullife.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