From: Steven Rostedt <rostedt@goodmis.org>
To: Manfred Spraul <manfred@colorfullife.com>
Cc: Linux Kernel Mailing List <linux-kernel@vger.kernel.org>
Subject: Re: kernel stack size
Date: Sun, 03 Apr 2005 14:01:44 -0400 [thread overview]
Message-ID: <1112551304.27149.126.camel@localhost.localdomain> (raw)
In-Reply-To: <424F96DD.2070307@colorfullife.com>
On Sun, 2005-04-03 at 09:10 +0200, Manfred Spraul wrote:
> Yes - sem or spin locks are quicker as long as no cache line transfers
> are necessary. If the semaphore is accessed by multiple cpus, then
> kmalloc would be faster: slab tries hard to avoid taking global locks.
> I'm not speaking about contention, just the cache line ping pong for
> acquiring a free semaphore.
Without contention, is there still a problem with cache line ping pong
of acquiring a free semaphore?
I mean, say only one task is using a given semaphore. Is there still
going to be cache line transfers for acquiring it? Even if the task in
question stays on a CPU. Is the "LOCK" on an instruction that expensive
even if the other CPUs haven't accessed that location of memory.
Sorry for my ignorance, I don't know all the interworkings of the Cache
on SMP systems. Is there any good references on the Internet? I
definitely want to know so that my coding practices for SMP improve.
Thanks,
-- Steve
next prev parent reply other threads:[~2005-04-03 18:01 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-04-02 20:14 Manfred Spraul
2005-04-02 22:15 ` Steven Rostedt
2005-04-03 7:10 ` Manfred Spraul
2005-04-03 18:01 ` Steven Rostedt [this message]
2005-04-03 19:23 ` Manfred Spraul
-- strict thread matches above, loose matches on Subject: below --
2005-04-02 17:46 ooyama eiichi
2005-04-02 17:53 ` Chris Wedgwood
2005-04-02 18:15 ` ooyama eiichi
2005-04-02 18:24 ` Chris Wedgwood
2005-04-02 18:48 ` ooyama eiichi
2005-04-02 19:04 ` Steven Rostedt
2005-04-02 19:37 ` Al Viro
2005-04-02 19:52 ` Steven Rostedt
2005-04-02 18:29 ` Brian Gerst
2003-10-09 19:14 Punj, Arun
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=1112551304.27149.126.camel@localhost.localdomain \
--to=rostedt@goodmis.org \
--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
Powered by JetHome