From: Andrea Arcangeli <andrea@suse.de>
To: David Howells <dhowells@warthog.cambridge.redhat.com>
Cc: torvalds@transmeta.com, linux-kernel@vger.kernel.org, davem@redhat.com
Subject: Re: rwsem benchmark [was Re: [PATCH] rw_semaphores, optimisations try #3]
Date: Tue, 24 Apr 2001 12:17:47 +0200 [thread overview]
Message-ID: <20010424121747.A1682@athlon.random> (raw)
In-Reply-To: <5927.988102571@warthog.cambridge.redhat.com>; from dhowells@warthog.cambridge.redhat.com on Tue, Apr 24, 2001 at 09:56:11AM +0100
On Tue, Apr 24, 2001 at 09:56:11AM +0100, David Howells wrote:
> | + : "+m" (sem->count), "+a" (sem)
^^^^^^^^^^ I think you were comenting on
the +m not +a ok
>
> >From what I've been told, you're lucky here... you avoid a pipeline stall
I see what you meant here and no, I'm not lucky, I thought about that. gcc
2.95.* seems smart enough to produce (%%eax) that you hardcoded when the sem is
not a constant (I'm not clobbering another register, if it does it's stupid and
I consider this a compiler mistake). I tried with a variable pointer and gcc
as I expected generated the (%%eax) but instead when it's a constant like in
the bench my way it avoids to stall the pipeline by using the constant address
for the locked incl, exactly as you said and that's probably why I beat you on
the down read fast path too. (I also benchmarked with a variable semaphore and
it was running a little slower)
Andrea
next prev parent reply other threads:[~2001-04-24 10:18 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2001-04-23 20:35 [PATCH] rw_semaphores, optimisations try #3 D.W.Howells
2001-04-23 21:34 ` Andrea Arcangeli
2001-04-24 4:56 ` rwsem benchmark [was Re: [PATCH] rw_semaphores, optimisations try #3] Andrea Arcangeli
2001-04-24 8:56 ` David Howells
2001-04-24 9:49 ` Andrea Arcangeli
2001-04-24 10:25 ` David Howells
2001-04-24 10:44 ` Andrea Arcangeli
2001-04-24 13:07 ` David Howells
2001-04-24 13:59 ` Andrea Arcangeli
2001-04-24 15:49 ` Linus Torvalds
2001-04-24 10:17 ` Andrea Arcangeli [this message]
2001-04-24 10:33 ` David Howells
2001-04-24 10:46 ` Andrea Arcangeli
2001-04-24 12:19 ` Andrea Arcangeli
2001-04-24 13:10 ` Andrea Arcangeli
2001-04-23 22:23 ` [PATCH] rw_semaphores, optimisations try #3 Linus Torvalds
2001-04-24 10:05 ` David Howells
2001-04-24 15:40 ` Linus Torvalds
2001-04-24 16:37 ` David Howells
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=20010424121747.A1682@athlon.random \
--to=andrea@suse.de \
--cc=davem@redhat.com \
--cc=dhowells@warthog.cambridge.redhat.com \
--cc=linux-kernel@vger.kernel.org \
--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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.