
Multi-threaded emulation for QEMU - webaholic
https://lwn.net/Articles/697265/
======
bonzini
Here is a paper from last month's CGO2017 conference, explaining the
techniques more in detail:
[http://www.cs.columbia.edu/~cota/pubs/cota_cgo17.pdf](http://www.cs.columbia.edu/~cota/pubs/cota_cgo17.pdf)

------
0xcde4c3db
For some reason I thought the reason that this hadn't been implemented already
was that Sony had patents on multithreaded binary translation. I guess those
might have only applied to specific techniques for heterogeneous or ring-bus
systems (i.e. Cell), though.

~~~
pm215
No, it's just that it's the kind of feature that's quite hard to retrofit to
an existing design, since it breaks existing assumptions in a lot of places.
And it's only relatively recently that the kind of embedded board that you
usually want to emulate with QEMU has had a multi-core CPU.

------
webaholic
This has recently landed in upstream qemu and will be available with the 2.9
release.

~~~
bonzini
Some bugs are being found that affect single-vCPU emulation. There's still a
possibility that it will be reverted before the release.

------
compsciphd
does this mean one could run (without hardware support, say in aws) smp
virtualization? i.e. linux on linux or windows on linux (why not just spawn
another machine? because you want to have more control than what aws provides)

~~~
webaholic
This allows you to create one host thread per guest vcpu, so yes, you can run
a smp guest on aws. But, it will be pretty slow compared to KVM, since the
execution of the threads is limited by the host cpu resources and the fact
that you are using translation and full system emulation.

~~~
compsciphd
so I guess that means QEMU always does full translation instead of just
translating the privileged ops? (ala what vmware's innovation back in the day
was)

