Patent ID: 7783681

Claim:
A method for providing concurrent garbage collection, in a computer system, comprising: identifying a set of objects for memory allocation by a memory manager, the identified objects required by an application running on a mutator; pre-marking the identified objects during a pre-marking phase using a reachability graph, the pre-marking designating the identified objects as active objects to be retained for at least a current cycle of the garbage collection; executing a garbage collector concurrently with the mutator to dynamically compute a set of recyclable objects in memory at the end of each cycle of garbage collection, the recyclable objects identified by the absence of markings; activating one or more barriers by the mutator after pre-marking the identified objects, the one or more barriers allowing the garbage collector to recursively scan objects in the reachability graph including the pre-marked objects and to finish the current cycle of garbage collection by marking objects and guarantying that objects not marked are no longer useful for the mutator and can be recycled; completing the current cycle of garbage collection, wherein the objects that are not marked are recycled and wherein the one or more barriers that were activated by the mutator are deactivated; and computing a new set of pre-marked objects before the activation of the barriers for a subsequent cycle of garbage collection.