On 15.06.2011, at 01:34, Scott Wood wrote:

> This is a shared page used for paravirtualization.  It is always present
> in the guest kernel's effective address space at the address indicated
> by the hypercall that enables it.
> 
> The physical address specified by the hypercall is not used, as
> e500 does not have real mode.

What are your results when using the magic page? I have the following numbers 
with your patches applied:

== bare metal ==

root@e500:~/kvm# time for i in {1..1000}; do /bin/echo > /dev/null; done

real    0m5.445s
user    0m0.204s
sys     0m0.572s


== no hypervisor node (magic page not used) ==

debian-powerpc:~# time for i in {1..1000}; do /bin/echo > /dev/null; done

real    1m36.362s
user    0m13.224s
sys     1m11.084s


== with hypervisor node (magic page used) ==

debian-powerpc:~# time for i in {1..1000}; do /bin/echo > /dev/null; done

real    2m28.888s
user    0m9.248s
sys     1m4.016s


This seems rather irritating to me. I haven't tried to trace what's going on, 
but trapping instructions really shouldn't be much better than mapping the 
magic page, plus the magic page should stay in memory.

... unless of course we're in the dynamically generated code paths. Then we get 
plenty of TLB misses instead of instruction emulation traps.

Either way, certainly something to check before we enable the magic page in 
Qemu.


Alex

--
To unsubscribe from this list: send the line "unsubscribe kvm-ppc" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to