From: Anthony Liguori <anthony@codemonkey.ws>
To: Paolo Bonzini <pbonzini@redhat.com>
Cc: Sasha Levin <levinsasha928@gmail.com>,
Jan Kiszka <jan.kiszka@web.de>, Pekka Enberg <penberg@kernel.org>,
mingo@elte.hu, avi@redhat.com, linux-kernel@vger.kernel.org,
kvm@vger.kernel.org, gorcunov@gmail.com, asias.hejun@gmail.com,
prasadjoshi124@gmail.com
Subject: Re: [GIT PULL] Native Linux KVM tool for 3.1
Date: Mon, 25 Jul 2011 08:16:10 -0500 [thread overview]
Message-ID: <4E2D6C9A.0@codemonkey.ws> (raw)
In-Reply-To: <4E2D6896.5010008@redhat.com>
On 07/25/2011 07:59 AM, Paolo Bonzini wrote:
> On 07/25/2011 09:50 AM, Sasha Levin wrote:
>> Anthony had a talk on last years KVM forum regarding the QEMU threading
>> model (slide:
>> http://www.linux-kvm.org/wiki/images/7/70/2010-forum-threading-qemu.pdf)
>> .
>>
>> It was suggested that the KVM part of QEMU is having a hard time
>> achieving the ideal threading model due to its need to support TCG -
>> something which has nothing to do with KVM itself.
>
> No, it is not having a hard time. The "foot in the door" that Anthony
> mentions has been part of QEMU and qemu-kvm for a long time
> (multi-threading is necessary to support SMP!) and works quite well.
>
>
> Historically, there were three main loops:
>
> 1) QEMU single-threaded;
>
> 2) QEMU multi-threaded; clean, but buggy, untested and bitrotting;
>
> 3) qemu-kvm multi-threaded, forked from (1), ugly but robust and widely
> deployed.
>
> In 0.15 the two multi-threaded versions have been unified by Jan Kiszka.
> I have even ported (2) to Windows with little or no pain; porting to Mac
> OS X interestingly is harder than Windows, because non-portable Linux
> assumptions about signal handling have crept in the code (to preempt the
> objections: they weren't just non-portabilities, they were latent bugs).
> Windows just does not have signals. :)
>
> So, right now, the only difference is that QEMU is still defaulting to
> the single-threaded main loop, while qemu-kvm enables multi-threading by
> default. In some time even QEMU will switch.
>
> Yes, this is of course worse than getting it right in the first place;
> Nobody is saying the opposite.
In all fairness, the fact that TCG requires signals to break execution
does complicate the QEMU code a fair bit. But that's because signals
are tricky to get right, not that the model is fundamentally complicated.
Regards,
Anthony Liguori
>
> Paolo
> --
> To unsubscribe from this list: send the line "unsubscribe kvm" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
next prev parent reply other threads:[~2011-07-25 13:16 UTC|newest]
Thread overview: 70+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-07-24 20:37 [GIT PULL] Native Linux KVM tool for 3.1 Pekka Enberg
2011-07-24 23:12 ` Jan Kiszka
2011-07-25 7:37 ` Pekka Enberg
2011-07-25 7:53 ` Ingo Molnar
2011-07-25 8:14 ` Alexander Graf
2011-07-25 8:23 ` Pekka Enberg
2011-07-25 8:31 ` Alexander Graf
2011-07-25 8:35 ` Avi Kivity
2011-07-25 13:10 ` Joerg Roedel
2011-07-25 15:05 ` Avi Kivity
2011-07-25 8:37 ` Pekka Enberg
2011-07-25 8:44 ` Alexander Graf
2011-07-25 8:51 ` Pekka Enberg
2011-07-25 8:55 ` Alexander Graf
2011-07-25 9:16 ` Ingo Molnar
2011-07-25 9:14 ` Ingo Molnar
2011-07-25 8:30 ` Pekka Enberg
2011-07-25 8:37 ` Alexander Graf
2011-07-25 8:47 ` Pekka Enberg
2011-07-25 9:06 ` Alexander Graf
2011-07-25 12:45 ` Pekka Enberg
2011-07-25 12:47 ` Avi Kivity
2011-07-25 12:51 ` Sasha Levin
2011-07-25 12:54 ` Alexander Graf
2011-07-25 13:14 ` Sasha Levin
2011-07-25 12:51 ` Alexander Graf
2011-07-25 13:09 ` Pekka Enberg
2011-07-25 13:29 ` Alexander Graf
2011-07-25 9:26 ` Ingo Molnar
2011-07-25 9:42 ` Alexander Graf
2011-07-25 10:16 ` Ingo Molnar
2011-07-25 10:21 ` Alexander Graf
2011-07-25 10:35 ` Ingo Molnar
2011-07-25 10:47 ` Ingo Molnar
2011-07-25 12:24 ` Kevin Wolf
2011-07-25 12:41 ` Pekka Enberg
2011-07-25 12:46 ` Avi Kivity
2011-07-25 8:54 ` Ingo Molnar
2011-07-25 8:59 ` Ingo Molnar
2011-07-25 9:03 ` Alexander Graf
2011-07-25 9:41 ` Ingo Molnar
2011-07-25 9:46 ` Alexander Graf
2011-07-25 10:28 ` Ingo Molnar
2011-07-25 9:48 ` Avi Kivity
2011-07-25 10:03 ` Ingo Molnar
2011-07-25 10:17 ` Avi Kivity
2011-07-25 10:29 ` Ingo Molnar
2011-07-25 11:26 ` Olivier Galibert
2011-07-25 10:38 ` Christoph Hellwig
2011-07-25 11:08 ` Ingo Molnar
2011-07-25 11:24 ` Christoph Hellwig
2011-07-25 11:32 ` Ingo Molnar
2011-07-25 11:34 ` Olivier Galibert
2011-07-25 11:41 ` Christoph Hellwig
2011-07-25 12:09 ` Ingo Molnar
2011-07-25 12:36 ` Pekka Enberg
2011-07-25 19:21 ` david
2011-07-25 18:24 ` Jan Kiszka
2011-07-25 19:43 ` Pekka Enberg
2011-07-25 7:50 ` Sasha Levin
2011-07-25 8:34 ` Alexander Graf
2011-07-25 12:59 ` Paolo Bonzini
2011-07-25 13:16 ` Anthony Liguori [this message]
2011-07-25 1:19 ` Anthony Liguori
2011-07-25 7:27 ` Pekka Enberg
2011-07-25 7:36 ` Avi Kivity
2011-07-25 7:39 ` Pekka Enberg
2011-07-25 7:55 ` Sasha Levin
[not found] ` <CAFO3S428qqUAu19QjPxDDAVv+eJSX0MEfYp5y03znNi6XbEtTg@mail.gmail.com>
2011-07-25 8:11 ` Ingo Molnar
2011-07-25 8:17 ` Pekka Enberg
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=4E2D6C9A.0@codemonkey.ws \
--to=anthony@codemonkey.ws \
--cc=asias.hejun@gmail.com \
--cc=avi@redhat.com \
--cc=gorcunov@gmail.com \
--cc=jan.kiszka@web.de \
--cc=kvm@vger.kernel.org \
--cc=levinsasha928@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@elte.hu \
--cc=pbonzini@redhat.com \
--cc=penberg@kernel.org \
--cc=prasadjoshi124@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.