Re: [PATCH] kvm: x86: mmu: Make NX huge page recovery period configurable

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 10/16/21 12:00 AM, Paolo Bonzini wrote:
On 16/10/21 02:50, Junaid Shahid wrote:
Currently, the NX huge page recovery thread wakes up every minute and
zaps 1/nx_huge_pages_recovery_ratio of the total number of split NX
huge pages at a time. This is intended to ensure that only a
relatively small number of pages get zapped at a time. But for very
large VMs (or more specifically, VMs with a large number of
executable pages), a period of 1 minute could still result in this
number being too high (unless the ratio is changed significantly,
but that can result in split pages lingering on for too long).

This change makes the period configurable instead of fixing it at
1 minute (though that is still kept as the default). Users of
large VMs can then adjust both the ratio and the period together to
reduce the number of pages zapped at one time while still
maintaining the same overall duration for cycling through the
entire list (e.g. the period could be set to 1 second and the ratio
to 3600 to maintain the overall cycling period of 1 hour).

The patch itself looks good, but perhaps the default (corresponding to a period of 0) could be 3600000 / ratio, so that it's enough to adjust the ratio?

Paolo


Sure, that sounds good. I'll send an updated version.

Thanks,
Junaid



[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux