From: Paolo Bonzini <pbonzini@redhat.com>
To: Stefan Hajnoczi <stefanha@gmail.com>
Cc: Arun R Bharadwaj <arun@linux.vnet.ibm.com>, qemu-devel@nongnu.org
Subject: [Qemu-devel] Re: [PATCH 1/3] Make paio subsystem use threadlets infrastructure
Date: Thu, 11 Nov 2010 09:41:28 +0100 [thread overview]
Message-ID: <4CDBAC38.4080901@redhat.com> (raw)
In-Reply-To: <AANLkTin3tPBDSc6YRuLJRM8s8kk+dyWYPdyiJBzN_WvU@mail.gmail.com>
On 11/10/2010 02:45 PM, Stefan Hajnoczi wrote:
> I wonder if the condition variable has a measurable performance
> overhead. We unconditionally broadcast on paiocb completion. One
> idea would be to keep a counter of waiters (should only ever be 0 or
> 1) protected by aiocb_mutex and broadcast only when there is a waiter.
This should be handled anyway by the pthreads library. If we are sure
there is only one waiter at most, you can change broadcast to signal but
that would already be microoptimization.
Alternatively, you can use futexes to implement a completion signal
(similar to Win32 events). But it seems too much effort.
Paolo
next prev parent reply other threads:[~2010-11-11 8:41 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-11-10 13:19 [Qemu-devel] v10: [PATCH 0/3] Threadlets: A generic task offloading framework Arun R Bharadwaj
2010-11-10 13:19 ` [Qemu-devel] [PATCH 1/3] Make paio subsystem use threadlets infrastructure Arun R Bharadwaj
2010-11-10 13:45 ` Stefan Hajnoczi
2010-11-10 17:54 ` Arun R Bharadwaj
2010-11-10 20:13 ` Stefan Hajnoczi
2010-11-11 8:41 ` Paolo Bonzini [this message]
2010-11-11 9:26 ` [Qemu-devel] " Stefan Hajnoczi
2010-11-10 13:19 ` [Qemu-devel] [PATCH 2/3] Move threadlets infrastructure to qemu-threadlets.c Arun R Bharadwaj
2010-11-10 13:47 ` Stefan Hajnoczi
2010-11-11 8:18 ` Arun R Bharadwaj
2010-11-10 17:29 ` Blue Swirl
2010-11-10 17:56 ` Arun R Bharadwaj
2010-11-10 13:19 ` [Qemu-devel] [PATCH 3/3] Add helper functions to enable virtio-9p make use of the threadlets Arun R Bharadwaj
2010-11-10 13:54 ` Stefan Hajnoczi
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=4CDBAC38.4080901@redhat.com \
--to=pbonzini@redhat.com \
--cc=arun@linux.vnet.ibm.com \
--cc=qemu-devel@nongnu.org \
--cc=stefanha@gmail.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.