public inbox for kvm@vger.kernel.org
 help / color / mirror / Atom feed
From: Michael Tokarev <mjt@tls.msk.ru>
To: KVM list <kvm@vger.kernel.org>
Subject: high load with win7 & usb tablet
Date: Fri, 03 Sep 2010 16:21:13 +0400	[thread overview]
Message-ID: <4C80E839.50604@msgid.tls.msk.ru> (raw)

Hello.

I noticed that window7, unlike windowsXP as I played with
previously, poses quite high load on host when idle.  On
my machine, host cpu usage is about 25% when one single-cpu
win7 guest is running with "-usbdevice tablet" option.
Here's a typical kvm_stats when such a guest is idling:

 efer_reload                  0       0
 exits                   991832     695
 fpu_reload                3786       0
 halt_exits                7759      67
 halt_wakeup               7717      67
 host_state_reload       613116     495
 hypercalls                   0       0
 insn_emulation          873244     488
 insn_emulation_fail          0       0
 invlpg                       0       0
 io_exits                582925     409
 irq_exits                30188       8
 irq_injections           41093       0
 irq_window                   0       0
 largepages                 288       0
 mmio_exits               16718       0
 mmu_cache_miss             217       0
 mmu_flooded                  0       0
 mmu_pde_zapped               0       0
 mmu_pte_updated              0       0
 mmu_pte_write                0       0
 mmu_recycled                 0       0
 mmu_shadow_zapped          269       0
 mmu_unsync                   0       0
 nmi_injections               0       0
 nmi_window                   0       0
 pf_fixed                 20630       0
 pf_guest                     0       0
 remote_tlb_flush           176       0
 request_irq                  0       0

Here -- http://www.corpit.ru/mjt/kvm-trace-w7-idle --
are some results from /sys/kernel/debug/tracing/events/kvm/enable
(taken from /sys/kernel/debug/tracing/trace_pipe).
The file's >5Mb in size.

When I run the same guest without -usbdevice tablet,
it idles at about 3..4% host CPU time -- still a bit
high but acceptable.

Here's a typical kvm_stats output withOUT usb tablet:

 efer_reload                  0       0
 exits                  1204081     686
 fpu_reload                4235       2
 halt_exits               12116      67
 halt_wakeup              12047      67
 host_state_reload       797865     493
 hypercalls                   0       0
 insn_emulation         1074589     473
 insn_emulation_fail          0       0
 invlpg                       0       0
 io_exits                761834     408
 irq_exits                22240      12
 irq_injections           33099       0
 irq_window                   0       0
 largepages                 304       0
 mmio_exits               16718       0
 mmu_cache_miss             220       0
 mmu_flooded                  0       0
 mmu_pde_zapped               0       0
 mmu_pte_updated              0       0
 mmu_pte_write                0       0
 mmu_recycled                 0       0
 mmu_shadow_zapped          271       0
 mmu_unsync                   0       0
 nmi_injections               0       0
 nmi_window                   0       0
 pf_fixed                 18790       0
 pf_guest                     0       0
 remote_tlb_flush           109       0
 request_irq                  0       0

And here's the two tables combined (last column from
the above two tables, without and with usbmouse):

statistics         without  with
efer_reload              0     0
exits                  686   695
fpu_reload               2     0
halt_exits              67    67
halt_wakeup             67    67
host_state_reload      493   495
hypercalls               0     0
insn_emulation         473   488
insn_emulation_fail      0     0
invlpg                   0     0
io_exits               408   409
irq_exits               12     8
irq_injections           0     0
irq_window               0     0
largepages               0     0
mmio_exits               0     0
mmu_cache_miss           0     0
mmu_flooded              0     0
mmu_pde_zapped           0     0
mmu_pte_updated          0     0
mmu_pte_write            0     0
mmu_recycled             0     0
mmu_shadow_zapped        0     0
mmu_unsync               0     0
nmi_injections           0     0
nmi_window               0     0
pf_fixed                 0     0
pf_guest                 0     0
remote_tlb_flush         0     0
request_irq              0     0

So basically they're quite similar to each other,
give or take some random fluctuations.

kvm version is 0.12.5, kvm command line:

 kvm -nodefaults -m 1G \
  -drive file=w7.raw,cache=none,boot=on,if=virtio \
  -monitor stdio \
  -vga std \
  -device virtio-net-pci,netdev=net \
  -netdev type=tap,ifname=tap-kvm,id=net
  -no-hpet
  -mem-path /dev/hugepages/

(and also -usbdevice tablet).  I especially disabled almost
everything (incl. hpet) and used "light" virtio drivers in
order to try to reduce load as much as possible.

The host CPU is AthlonII X2 260 (Regor).

Anyone know how to make w7 less idle-hungry for usb?

Thanks!

/mjt

             reply	other threads:[~2010-09-03 12:21 UTC|newest]

Thread overview: 36+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-09-03 12:21 Michael Tokarev [this message]
2010-09-10 11:47 ` high load with win7 & usb tablet Jes Sorensen
2010-09-10 12:16   ` Michael Tokarev
2010-09-10 16:17     ` high load with usb device Michael Tokarev
2010-09-12  9:26       ` Avi Kivity
2010-09-14  6:51         ` Michael Tokarev
2010-09-14  9:06           ` Avi Kivity
2010-09-14  9:08             ` Avi Kivity
2010-09-14 10:00               ` Michael Tokarev
2010-09-14 10:07                 ` Avi Kivity
2010-09-14 10:25                   ` Michael Tokarev
2010-09-14 10:39                     ` Avi Kivity
2010-09-14 11:02                       ` Michael Tokarev
2010-09-14 13:15                         ` Michael Tokarev
2010-09-14 13:25                           ` Avi Kivity
2010-09-14 13:29                             ` Michael Tokarev
2010-09-14 13:38                               ` Michael Tokarev
2010-09-14 14:45                               ` Avi Kivity
2010-09-14 14:53                                 ` Michael Tokarev
2010-09-14 16:00                                   ` Avi Kivity
2010-09-14 16:29                                     ` Michael Tokarev
2010-09-14 16:37                                       ` Avi Kivity
2010-09-14 16:50                                         ` Michael Tokarev
2010-09-14 16:45                                       ` David S. Ahern
2010-09-14 15:51                                 ` David S. Ahern
2010-09-14 16:00                                   ` Michael Tokarev
2010-09-14 16:09                                     ` David S. Ahern
2010-09-10 12:19 ` high load with win7 & usb tablet Avi Kivity
2010-09-10 12:44   ` Michael Tokarev
2010-09-10 12:50     ` Avi Kivity
     [not found]       ` <4C8A44E6.2060008@msgid.tls.msk.ru>
2010-09-10 14:56         ` Avi Kivity
2010-09-10 15:03           ` Michael Tokarev
2010-09-10 16:03             ` Avi Kivity
2010-09-14  8:26               ` Brad Campbell
2010-09-14  8:33                 ` Michael Tokarev
2010-09-14  8:46                   ` Brad Campbell

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=4C80E839.50604@msgid.tls.msk.ru \
    --to=mjt@tls.msk.ru \
    --cc=kvm@vger.kernel.org \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox