3491caf275
Some wakeups should not be considered a sucessful poll. For example on s390 I/O interrupts are usually floating, which means that _ALL_ CPUs would be considered runnable - letting all vCPUs poll all the time for transactional like workload, even if one vCPU would be enough. This can result in huge CPU usage for large guests. This patch lets architectures provide a way to qualify wakeups if they should be considered a good/bad wakeups in regard to polls. For s390 the implementation will fence of halt polling for anything but known good, single vCPU events. The s390 implementation for floating interrupts does a wakeup for one vCPU, but the interrupt will be delivered by whatever CPU checks first for a pending interrupt. We prefer the woken up CPU by marking the poll of this CPU as "good" poll. This code will also mark several other wakeup reasons like IPI or expired timers as "good". This will of course also mark some events as not sucessful. As KVM on z runs always as a 2nd level hypervisor, we prefer to not poll, unless we are really sure, though. This patch successfully limits the CPU usage for cases like uperf 1byte transactional ping pong workload or wakeup heavy workload like OLTP while still providing a proper speedup. This also introduced a new vcpu stat "halt_poll_no_tuning" that marks wakeups that are considered not good for polling. Signed-off-by: Christian Borntraeger <borntraeger@de.ibm.com> Acked-by: Radim Krčmář <rkrcmar@redhat.com> (for an earlier version) Cc: David Matlack <dmatlack@google.com> Cc: Wanpeng Li <kernellwp@gmail.com> [Rename config symbol. - Paolo] Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> |
||
---|---|---|
.. | ||
boot | ||
common | ||
configs | ||
crypto | ||
firmware | ||
include | ||
kernel | ||
kvm | ||
lib | ||
mach-alpine | ||
mach-artpec | ||
mach-asm9260 | ||
mach-at91 | ||
mach-axxia | ||
mach-bcm | ||
mach-berlin | ||
mach-clps711x | ||
mach-cns3xxx | ||
mach-davinci | ||
mach-digicolor | ||
mach-dove | ||
mach-ebsa110 | ||
mach-efm32 | ||
mach-ep93xx | ||
mach-exynos | ||
mach-footbridge | ||
mach-gemini | ||
mach-highbank | ||
mach-hisi | ||
mach-imx | ||
mach-integrator | ||
mach-iop13xx | ||
mach-iop32x | ||
mach-iop33x | ||
mach-ixp4xx | ||
mach-keystone | ||
mach-ks8695 | ||
mach-lpc18xx | ||
mach-lpc32xx | ||
mach-mediatek | ||
mach-meson | ||
mach-mmp | ||
mach-moxart | ||
mach-mv78xx0 | ||
mach-mvebu | ||
mach-mxs | ||
mach-netx | ||
mach-nomadik | ||
mach-nspire | ||
mach-omap1 | ||
mach-omap2 | ||
mach-orion5x | ||
mach-picoxcell | ||
mach-prima2 | ||
mach-pxa | ||
mach-qcom | ||
mach-realview | ||
mach-rockchip | ||
mach-rpc | ||
mach-s3c24xx | ||
mach-s3c64xx | ||
mach-s5pv210 | ||
mach-sa1100 | ||
mach-shmobile | ||
mach-socfpga | ||
mach-spear | ||
mach-sti | ||
mach-stm32 | ||
mach-sunxi | ||
mach-tango | ||
mach-tegra | ||
mach-u300 | ||
mach-uniphier | ||
mach-ux500 | ||
mach-versatile | ||
mach-vexpress | ||
mach-vt8500 | ||
mach-w90x900 | ||
mach-zx | ||
mach-zynq | ||
mm | ||
net | ||
nwfpe | ||
oprofile | ||
plat-iop | ||
plat-omap | ||
plat-orion | ||
plat-pxa | ||
plat-samsung | ||
plat-versatile | ||
probes | ||
tools | ||
vdso | ||
vfp | ||
xen | ||
Kconfig | ||
Kconfig-nommu | ||
Kconfig.debug | ||
Makefile |