On 29/11/2017 14:35, Roman Kagan wrote: >> >>> IMO, the long term solution is to make Linux guests not misbehave >>> when we stop lying about the L3 cache. Maybe we could provide a >>> "IPIs are expensive, please avoid them" hint in the KVM CPUID >>> leaf? > We already have it, it's the hypervisor bit ;) Seriously, I'm unaware > of hypervisors where IPIs aren't expensive. >
In theory, AMD's AVIC should optimize IPIs to running vCPUs. Amazon's recently posted patches to disable HLT and MWAIT exits might tilt the balance in favor of IPIs even for Intel APICv (where sending the IPI is expensive, but receiving it isn't). Being able to tie this to Amazon's other proposal, the "DEDICATED" CPUID bit, would be nice. My plan was to disable all three of MWAIT/HLT/PAUSE when setting the dedicated bit. Paolo