1. A method for managing memory of a runtime environment executing in a virtual machine, the method comprising: receiving, from a virtualization software that supports execution of the virtual machine, a target amount of memory to be reclaimed from the virtual machine; reclaiming a first portion of the target amount of memory from heap memory of the runtime environment, wherein the heap memory comprises guest physical memory reserved for and managed by the runtime environment; determining, by operation of a memory management agent in the runtime environment, a second portion of the target amount of memory to be reclaimed; identifying at least one guest physical memory page to be allocated as part of the runtime environment but external to the heap memory of the runtime environment, the one or more guest physical memory page having a size equal to the second portion of the target amount of memory to be reclaimed; and notifying a hypervisor that at least one machine memory page associated with the identified guest physical memory page can be re-claimed.