Patent ID: 7548940
Filing Date: 2009-06-16
Classification: G06F,Y10S

Abstract:
1. A partial heap garbage collector for managing a memory heap having a nursery portion and a non-nursery portion, the partial heap garbage collector comprising a processor unit including a computer readable processing code, wherein the computer readable processing code, when executing in the processor unit, configures the processor unit for: collecting data objects in the nursery portion in a defined collection period, said collection period including a plurality of intervals, each of said intervals including a mutator portion and a garbage collector portion; using time-based scheduling to guarantee that in each of the time intervals, a minimum amount of time is provided for the mutator portion by: checking, during said collection period, a parameter representing the amount of time or work remaining to complete a defined partial heap collection; based on the value of said parameter, moving collection work from one of said intervals to another of said intervals to finish a defined partial heap collection within said defined collection period; and changing the capacity of the nursery portion from one nursery collection to the next nursery collection to ensure that said next nursery collection is completed in the defined collection period; for each of a plurality of arrays of data objects, providing an arrayoid and one or more arraylets, the arrayoid including one or more pointers to said one or more arraylets, each of the arraylets being a continuous section of memory areas, and the arraylet size Σ is determined by the memory page size π and a given fragmentation ratio p, where Σ=ρπ; allocating the arraylets to the non-nursery portion of the memory, including the step of reducing an allocation limit for said nursery portion when one of said arraylets is allocated to said non- nursery portion of the memory using mixed forms of arraylets to bound the fragmentation by ρ; and moving the arrayoids to the non-nursery portion of the memory while keeping said pointers in the arrayoids unchanged, to reduce the cost of evacuating the arrays of data objects from the nursery portion of the memory; wherein said defined partial heap collection is guaranteed to complete within a fixed time interval, and said guarantee to complete the partial heap collection within the fixed time interval is obtained by applying a worst-case execution time (WCET) and sizing the nursery portion whereby complete evacuation of the nursery portion can always be achieved on time.