public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Andi Kleen <andi@firstfloor.org>
To: Frederic Weisbecker <fweisbec@gmail.com>
Cc: LKML <linux-kernel@vger.kernel.org>,
	Jeff Mahoney <jeffm@suse.com>,
	Peter Zijlstra <a.p.zijlstra@chello.nl>,
	ReiserFS Development List <reiserfs-devel@vger.kernel.org>,
	Bron Gondwana <brong@fastmail.fm>,
	Andrew Morton <akpm@linux-foundation.org>,
	Linus Torvalds <torvalds@linux-foundation.org>,
	Ingo Molnar <mingo@elte.hu>,
	Alexander Viro <viro@zeniv.linux.org.uk>
Subject: Re: [PATCH] reiserfs: kill-the-BKL
Date: Thu, 09 Apr 2009 17:15:09 +0200	[thread overview]
Message-ID: <87tz4x97uq.fsf@basil.nowhere.org> (raw)
In-Reply-To: <1239070789-13354-1-git-send-email-fweisbec@gmail.com> (Frederic Weisbecker's message of "Tue,  7 Apr 2009 04:19:49 +0200")

Frederic Weisbecker <fweisbec@gmail.com> writes:
>
> So the new lock that replaces the bkl here is a per superblock mutex 

You have to be very careful with this. Mutexes can be slower than
spinlocks (and the new BKL is a spinlock) in some situations, they
typically schedule much more etc., which can be costly. So this might
have actually made it slower if you're unlucky.  There were some
experimental changes recently to make mutexes more behave like
spinlocks, but I don't think they're fully performance equivalent.

Better would be to use spinlocks if possible. I guess you just would
need to find all sleep points and wrap them with lock dropping?

> After this patch, reiserfs suffers from a slight performance regression (for now).

That might be related to the scheduling  behaviour. Watch the reschedule
counters in vmstat 1

-Andi

-- 
ak@linux.intel.com -- Speaking for myself only.

  parent reply	other threads:[~2009-04-09 15:15 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-04-07  2:19 [PATCH] reiserfs: kill-the-BKL Frederic Weisbecker
2009-04-07 11:24 ` Frederic Weisbecker
2009-04-07 13:40 ` Ingo Molnar
2009-04-07 21:34 ` Alexander Beregalov
2009-04-07 21:57   ` Frederic Weisbecker
2009-04-07 22:19     ` Alexander Beregalov
2009-04-08  0:42       ` Frederic Weisbecker
2009-04-09 15:15 ` Andi Kleen [this message]
2009-04-09 15:35   ` Linus Torvalds
2009-04-09 18:40     ` Ingo Molnar
2009-04-09 19:36       ` Andi Kleen
2009-04-09 20:05         ` Frederic Weisbecker
2009-04-09 21:17         ` Ingo Molnar
2009-04-10  0:39           ` Bron Gondwana
2009-04-10 13:07             ` Ingo Molnar
2009-04-09 21:07   ` Ingo Molnar

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=87tz4x97uq.fsf@basil.nowhere.org \
    --to=andi@firstfloor.org \
    --cc=a.p.zijlstra@chello.nl \
    --cc=akpm@linux-foundation.org \
    --cc=brong@fastmail.fm \
    --cc=fweisbec@gmail.com \
    --cc=jeffm@suse.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@elte.hu \
    --cc=reiserfs-devel@vger.kernel.org \
    --cc=torvalds@linux-foundation.org \
    --cc=viro@zeniv.linux.org.uk \
    /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