Windows Server Core in a VM: reducing CPU wakeups when idle

Simon Richter 1 Reputation point
2021-02-08T15:22:32.957+00:00

Hi,

I have a VM with Windows Server 2019 Datacenter Core, running on a Linux host with KVM. Hyper-V extensions including vapic, synic and stimer are enabled.

The VM has 16 VCPUs assigned to it, and looking at the statistics, I can see that it stops executing 16,000 times per second with a HLT instruction, spends 965us (+/- 0.05%) suspended, and then restarts. This smells like a 1 kHz timer on every CPU, and we seem to be spending about 3-5% of host CPU time on this, as well as interrupting the other VMs.

Can Windows be configured to idle more efficiently here, e.g. by adjusting the frequency of that timer or disabling it completely? Is there a "tickless idle" mode?

For comparison, an idle Linux VM on the same machine has a single-digit number of VM-Exit events per second.

Windows for business Windows Server User experience Other
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Mico Mi 1,936 Reputation points
    2021-02-09T06:22:03.09+00:00

    Hi,
    Please check Kayant12's post in the following thread, I hope it could help at your side:
    https://www.reddit.com/r/VFIO/comments/d5z0cb/kvm_high_idle_use_in_win10/

    Thanks for your time!
    Best Regards,
    Mico Mi

    -----------------------------

    If the Answer is helpful, please click "Accept Answer" and upvote it.
    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.