From: Jiri Kosina <jkosina@suse.cz>
To: Ingo Molnar <mingo@elte.hu>
Cc: linux-kernel@vger.kernel.org
Subject: Re: spinlocks -- why are releases inlined and acquires are not?
Date: Tue, 1 Apr 2008 10:38:41 +0200 (CEST) [thread overview]
Message-ID: <Pine.LNX.4.64.0804011034410.5541@jikos.suse.cz> (raw)
In-Reply-To: <20080401083359.GB32272@elte.hu>
On Tue, 1 Apr 2008, Ingo Molnar wrote:
> > > What is the reason for this asymetry? Shouldn't the acquiring
> > > functions be implemented in the very same way? Or at least,
> > > shouldn't all the __lockfunc functions be inlined?
> > i.e. is there any particular reason why we don't have something like
> > the patch below (implemented for all the lock variants of course, this
> > is just to demonstrate what I mean)?
> IIRC the main reason we decided to uninline them was image size. So i'd
> suggest for you to check how this change impacts vmlinux size (on both
> 64-bit and 32-bit), a typical distro config (or allyesconfig with lock
> debugging disabled). If you do the test on x86.git/latest you'll also
> have the CONFIG_OPTIMIZE_INLINING=y and CONFIG_CC_OPTIMIZE_FOR_SIZE=y
> combination as well, which generates the most compact x86 kernel image
> ever.
In fact we have received report from one of our users that he is seeing
approximately 15% performance degradation of mmap() when spinlocks are not
inlined. I am going to do some performance measurements myself shortly, as
it seems quite strange, but while at it, I have noticed the aforementioned
asymetry in spinlock.h, so I just wanted to know if there is any
particular reason behind that.
--
Jiri Kosina
SUSE Labs
next prev parent reply other threads:[~2008-04-01 8:38 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-04-01 0:08 Jiri Kosina
2008-04-01 0:40 ` Jiri Kosina
2008-04-01 8:33 ` Ingo Molnar
2008-04-01 8:38 ` Jiri Kosina [this message]
2008-04-01 8:43 ` Ingo Molnar
2008-04-01 8:44 ` Jiri Kosina
2008-04-01 11:12 ` Andi Kleen
2008-04-01 12:40 ` Jiri Kosina
2008-04-01 13:30 ` Andi Kleen
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.64.0804011034410.5541@jikos.suse.cz \
--to=jkosina@suse.cz \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@elte.hu \
/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®