Patent ID: 9710372
Date: 2017-07-18
CPC Classifications: G06F

Claim:
1. A system comprising: one or more physical processors; a hypervisor executing on the one or more physical processors; a host operating system (OS) executing on the one or more physical processors; and a virtual machine, including a guest operating system (OS), executing on the one or more physical processors to: receive, by the guest OS executing on the virtual machine, from the hypervisor, a request, wherein the request requests guest memory to be made available to the host OS; receive, by the guest OS, a huge page size of a host page and a quantity of requested guest memory; responsive to receiving the request, allocate, by the guest OS, unused guest memory and transmit, by the guest OS, at least one address of the allocated guest memory to the hypervisor, wherein the allocated guest memory is a contiguous block of memory that is at least the size of the huge page size of the host page; and determine, by the hypervisor, that the allocated guest memory is not reclaimable responsive to determining that the allocated guest memory is (a) not a multiple of the huge page size of the host page or (b) not aligned to the multiple of the huge page size of the host page.