Patent ID: 7174354

Claim:
A system for memory management comprising: a computer system including a virtual machine operating thereon; a memory space within said computer system and accessible by the virtual machine for the runtime storage and execution of applications; and, a garbage collector that uses a reinforcement learning process to control the allocation of memory to applications within the memory space; wherein the garbage collector performs the steps of (a) measuring system-wide and application-specific parameters, and system events, to determine a current state of the memory space, including the degree of fragmentation in the memory space, (b) performing an action to adjust the allocation of memory in the memory space, including garbage collecting the memory space, (c) calculating a reward value that indicates the success of the action on the memory space, including adding or subtracting preset values for specified actions of the garbage collector or conditions of the memory space, (d) storing information about the state, action and reward value for subsequent use by the garbage collector, (e) subsequently measuring the system-wide and application-specific parameters, and system events, to determine a new state of the memory space, (f) retrieving and using the stored information about the state, action and reward value to determine an optimal action that the garbage collector should perform on the memory space to maximize a likely future reward value, (g) performing the determined action by the garbage collector to adjust the allocation of memory, (h) calculating a new reward value that indicates the success of the determined action on the memory space, and, (i) repeating steps (d) through (h) to control the allocation of memory to applications within the memory space.