>On Thu, Nov 20, 2014 at 02:59:36PM +0800, Zhang Haoyu wrote: >> >On 20/11/2014 03:20, Zhang Haoyu wrote: >> >> Hi all, >> >> >> >> If I press the one of "Insert/Delete/Home/End/PageUp/PageDown/UpArrow/ >> >> DownArrow/LeftArrow/RightArrow" key w/o releasing, then lots of interrupts >> >> will be injected to vm(win7/win2008), about 8000/s, the system become very slow, >> >> bringing very bad experience. But the other keys are okay. >> >> And, linux guest has no this problem. >> > >> >Do you have a trace for this? What version of QEMU and what UI backend? >> > >> Sorry for forgetting to mention test environment from the start. >> Host: rhel7 with kernel-3.10.0-121 >> QEMU: qemu-2.0.2 >> Guest: win7(bad),win2008(bad),linux-kernel-3.10.0-121(good) >> >> No UI backend, directly start the VM via qemu command. >> >> perf top data when above problem happening: >Trace it like this: http://www.linux-kvm.org/page/Tracing trace data while pressing "downArrow" key w/o releasing:(the vm has 2 vcpus) version = 6 CPU 2 is empty cpus=16 kvm-16063 [000] 8312.322731: kvm_pio: pio_read at 0x64 size 1 count 1 kvm-16062 [003] 8312.322732: kvm_exit: reason PAUSE_INSTRUCTION rip 0x805466c0 info 0 0 kvm-16062 [003] 8312.322733: kvm_entry: vcpu 0 kvm-16063 [000] 8312.322733: kvm_userspace_exit: reason KVM_EXIT_IO (2) kvm-16062 [003] 8312.322736: kvm_exit: reason PAUSE_INSTRUCTION rip 0x805466c0 info 0 0 kvm-16062 [003] 8312.322736: kvm_entry: vcpu 0 kvm-16063 [000] 8312.322736: kvm_entry: vcpu 1 kvm-16063 [000] 8312.322737: kvm_exit: reason CPUID rip 0x806e7fbb info 0 0 kvm-16063 [000] 8312.322738: kvm_cpuid: func 0 rax a rbx 756e6547 rcx 6c65746e rdx 49656e69 kvm-16062 [003] 8312.322738: kvm_exit: reason PAUSE_INSTRUCTION rip 0x805466c0 info 0 0 kvm-16063 [000] 8312.322738: kvm_entry: vcpu 1 kvm-16062 [003] 8312.322739: kvm_entry: vcpu 0 kvm-16063 [000] 8312.322739: kvm_exit: reason IO_INSTRUCTION rip 0x806edf72 info b008000b 0 kvm-16063 [000] 8312.322740: kvm_pio: pio_read at 0xb008 size 4 count 1 kvm-16063 [000] 8312.322740: kvm_entry: vcpu 1 kvm-16062 [003] 8312.322741: kvm_exit: reason PAUSE_INSTRUCTION rip 0x805466c0 info 0 0 kvm-16063 [000] 8312.322741: kvm_exit: reason IO_INSTRUCTION rip 0x806edf72 info b008000b 0 kvm-16062 [003] 8312.322741: kvm_entry: vcpu 0 kvm-16063 [000] 8312.322742: kvm_pio: pio_read at 0xb008 size 4 count 1 kvm-16063 [000] 8312.322742: kvm_entry: vcpu 1 kvm-16063 [000] 8312.322743: kvm_exit: reason IO_INSTRUCTION rip 0x806eda5a info 640008 0 kvm-16063 [000] 8312.322743: kvm_pio: pio_read at 0x64 size 1 count 1 kvm-16062 [003] 8312.322744: kvm_exit: reason PAUSE_INSTRUCTION rip 0x805466c0 info 0 0 kvm-16063 [000] 8312.322744: kvm_userspace_exit: reason KVM_EXIT_IO (2) kvm-16062 [003] 8312.322744: kvm_entry: vcpu 0 kvm-16062 [003] 8312.322746: kvm_exit: reason PAUSE_INSTRUCTION rip 0x805466c0 info 0 0 kvm-16062 [003] 8312.322747: kvm_entry: vcpu 0 kvm-16063 [000] 8312.322747: kvm_entry: vcpu 1 kvm-16063 [000] 8312.322748: kvm_exit: reason CPUID rip 0x806e7fbb info 0 0 kvm-16063 [000] 8312.322748: kvm_cpuid: func 0 rax a rbx 756e6547 rcx 6c65746e rdx 49656e69 kvm-16063 [000] 8312.322749: kvm_entry: vcpu 1 kvm-16062 [003] 8312.322749: kvm_exit: reason PAUSE_INSTRUCTION rip 0x805466c0 info 0 0 kvm-16062 [003] 8312.322749: kvm_entry: vcpu 0 kvm-16063 [000] 8312.322749: kvm_exit: reason IO_INSTRUCTION rip 0x806edf72 info b008000b 0 kvm-16063 [000] 8312.322750: kvm_pio: pio_read at 0xb008 size 4 count 1 kvm-16063 [000] 8312.322751: kvm_entry: vcpu 1 kvm-16062 [003] 8312.322751: kvm_exit: reason PAUSE_INSTRUCTION rip 0x805466c0 info 0 0 kvm-16063 [000] 8312.322751: kvm_exit: reason IO_INSTRUCTION rip 0x806edf72 info b008000b 0 kvm-16062 [003] 8312.322752: kvm_entry: vcpu 0 kvm-16063 [000] 8312.322752: kvm_pio: pio_read at 0xb008 size 4 count 1 ... trace data while pressing "downArrow" key w/o releasing:(the vm has 1 vcpus) version = 6 CPU 4 is empty CPU 5 is empty CPU 6 is empty CPU 7 is empty CPU 10 is empty CPU 11 is empty CPU 12 is empty CPU 13 is empty CPU 14 is empty CPU 15 is empty cpus=16 kvm-27755 [002] 19299.396888: kvm_set_irq: gsi 8 level 1 source 0 kvm-27755 [002] 19299.396891: kvm_pic_set_irq: chip 1 pin 0 (edge|masked) kvm-27755 [002] 19299.396895: kvm_apic_accept_irq: apicid 0 vec 209 (Fixed|edge) kvm-27755 [002] 19299.396895: kvm_ioapic_set_irq: pin 8 dst 1 vec=209 (Fixed|logical|edge) kvm-27769 [000] 19299.396901: kvm_inj_virq: irq 209 kvm-27769 [000] 19299.396903: kvm_entry: vcpu 0 kvm-27769 [000] 19299.396906: kvm_exit: reason IO_INSTRUCTION rip 0x806e5f29 info 700040 0 kvm-27769 [000] 19299.396908: kvm_pio: pio_write at 0x70 size 1 count 1 kvm-27769 [000] 19299.397039: kvm_userspace_exit: reason KVM_EXIT_IO (2) kvm-27769 [000] 19299.397045: kvm_entry: vcpu 0 kvm-27769 [000] 19299.397047: kvm_exit: reason IO_INSTRUCTION rip 0x806e5f31 info 710048 0 kvm-27769 [000] 19299.397047: kvm_pio: pio_read at 0x71 size 1 count 1 kvm-27769 [000] 19299.397048: kvm_userspace_exit: reason KVM_EXIT_IO (2) kvm-27769 [000] 19299.397050: kvm_set_irq: gsi 8 level 0 source 0 kvm-27769 [000] 19299.397051: kvm_pic_set_irq: chip 1 pin 0 (edge|masked) kvm-27769 [000] 19299.397051: kvm_ioapic_set_irq: pin 8 dst 1 vec=209 (Fixed|logical|edge) kvm-27769 [000] 19299.397053: kvm_entry: vcpu 0 kvm-27769 [000] 19299.397053: kvm_exit: reason IO_INSTRUCTION rip 0x806e5f3b info 700040 0 kvm-27769 [000] 19299.397054: kvm_pio: pio_write at 0x70 size 1 count 1 kvm-27769 [000] 19299.397054: kvm_userspace_exit: reason KVM_EXIT_IO (2) kvm-27769 [000] 19299.397056: kvm_entry: vcpu 0 kvm-27769 [000] 19299.397056: kvm_exit: reason IO_INSTRUCTION rip 0x806e5f43 info 710048 0 kvm-27769 [000] 19299.397057: kvm_pio: pio_read at 0x71 size 1 count 1 kvm-27769 [000] 19299.397057: kvm_userspace_exit: reason KVM_EXIT_IO (2) kvm-27769 [000] 19299.397058: kvm_set_irq: gsi 8 level 0 source 0 kvm-27769 [000] 19299.397059: kvm_pic_set_irq: chip 1 pin 0 (edge|masked) kvm-27769 [000] 19299.397059: kvm_ioapic_set_irq: pin 8 dst 1 vec=209 (Fixed|logical|edge) kvm-27769 [000] 19299.397060: kvm_entry: vcpu 0 kvm-27769 [000] 19299.397061: kvm_exit: reason APIC_ACCESS rip 0x806e7f18 info 10b0 0 kvm-27769 [000] 19299.397062: kvm_apic: apic_write APIC_EOI = 0x0 kvm-27769 [000] 19299.397062: kvm_eoi: apicid 0 vector 209 kvm-27769 [000] 19299.397063: kvm_ack_irq: irqchip IOAPIC pin 8 kvm-27769 [000] 19299.397064: kvm_entry: vcpu 0 kvm-27769 [000] 19299.397066: kvm_exit: reason IO_INSTRUCTION rip 0x806edf72 info b008000b 0 kvm-27769 [000] 19299.397066: kvm_pio: pio_read at 0xb008 size 4 count 1 kvm-27769 [000] 19299.397067: kvm_entry: vcpu 0 kvm-27769 [000] 19299.397068: kvm_exit: reason IO_INSTRUCTION rip 0x806edf72 info b008000b 0 kvm-27769 [000] 19299.397069: kvm_pio: pio_read at 0xb008 size 4 count 1 kvm-27769 [000] 19299.397069: kvm_entry: vcpu 0 kvm-27769 [000] 19299.397070: kvm_exit: reason HLT rip 0xf878c161 info 0 0 kvm-27755 [002] 19299.412667: kvm_set_irq: gsi 8 level 1 source 0 kvm-27755 [002] 19299.412668: kvm_pic_set_irq: chip 1 pin 0 (edge|masked) kvm-27755 [002] 19299.412671: kvm_apic_accept_irq: apicid 0 vec 209 (Fixed|edge) kvm-27755 [002] 19299.412672: kvm_ioapic_set_irq: pin 8 dst 1 vec=209 (Fixed|logical|edge) kvm-27769 [000] 19299.412678: kvm_inj_virq: irq 209 kvm-27769 [000] 19299.412679: kvm_entry: vcpu 0 kvm-27769 [000] 19299.412683: kvm_exit: reason IO_INSTRUCTION rip 0x806e5f29 info 700040 0 kvm-27769 [000] 19299.412684: kvm_pio: pio_write at 0x70 size 1 count 1 kvm-27769 [000] 19299.412686: kvm_userspace_exit: reason KVM_EXIT_IO (2) kvm-27769 [000] 19299.412712: kvm_entry: vcpu 0 kvm-27769 [000] 19299.412713: kvm_exit: reason IO_INSTRUCTION rip 0x806e5f31 info 710048 0 kvm-27769 [000] 19299.412713: kvm_pio: pio_read at 0x71 size 1 count 1 kvm-27769 [000] 19299.412714: kvm_userspace_exit: reason KVM_EXIT_IO (2) kvm-27769 [000] 19299.412716: kvm_set_irq: gsi 8 level 0 source 0 Thanks, Zhang Haoyu -- To unsubscribe from this list: send the line "unsubscribe kvm" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html