KVM: optimize apic interrupt delivery
authorGleb Natapov <gleb@redhat.com>
Thu, 13 Sep 2012 14:19:24 +0000 (17:19 +0300)
committerAvi Kivity <avi@redhat.com>
Thu, 20 Sep 2012 12:05:26 +0000 (15:05 +0300)
commit1e08ec4a130e2745d96df169e67c58df98a07311
tree362647f5b0bac59e7fe93ce66775afac2cd7da79
parent1d86b5cc4c6d9a1be1458be3701ac9c915a9706f
KVM: optimize apic interrupt delivery

Most interrupt are delivered to only one vcpu. Use pre-build tables to
find interrupt destination instead of looping through all vcpus. In case
of logical mode loop only through vcpus in a logical cluster irq is sent
to.

Signed-off-by: Gleb Natapov <gleb@redhat.com>
Acked-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: Avi Kivity <avi@redhat.com>
arch/x86/include/asm/kvm_host.h
arch/x86/kvm/lapic.c
arch/x86/kvm/lapic.h
arch/x86/kvm/x86.c
virt/kvm/irq_comm.c