Trace termination for on-the-fly garbage collection for weakly-consistent computer architecture
First Claim
1. A method for memory management in execution of a program by a computer having a memory, comprising:
- allocating respective portions of the memory to data objects using mutator threads of the program, whereby the objects are held in a heap created by the program;
tracing the data objects in the heap so as to mark the data objects that are reachable at a given stage in the program;
looping over the mutator threads so as to verify for each of the mutator threads that every update to the allocated portions of the memory in progress by the mutator thread has been completed; and
sweeping the heap so as to free the memory that is allocated to the data objects that are not marked as reachable, for reallocation to new data objects.
1 Assignment
0 Petitions
Accused Products
Abstract
A method for memory management in execution of a program by a computer having a memory includes allocating respective portions of the memory to data objects using mutator threads of the program, whereby the objects are held in a heap created by the program. The data objects in the heap are traced so as to mark the data objects that are reachable at a given stage in the program. The computer loops over the mutator threads so as to verify for each of the mutator threads that every update to the allocated portions of the memory in progress by the mutator thread has been completed. The heap is then swept so as to free the memory that is allocated to the data objects that are not marked as reachable, for reallocation to new data objects.
29 Citations
36 Claims
-
1. A method for memory management in execution of a program by a computer having a memory, comprising:
-
allocating respective portions of the memory to data objects using mutator threads of the program, whereby the objects are held in a heap created by the program;
tracing the data objects in the heap so as to mark the data objects that are reachable at a given stage in the program;
looping over the mutator threads so as to verify for each of the mutator threads that every update to the allocated portions of the memory in progress by the mutator thread has been completed; and
sweeping the heap so as to free the memory that is allocated to the data objects that are not marked as reachable, for reallocation to new data objects. - View Dependent Claims (2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36)
-
-
13. Computing apparatus, comprising:
-
a memory, arranged to store data; and
one or more processors, coupled to allocate respective portions of the memory to data objects using mutator threads of a program running on the apparatus, whereby the objects are held in a heap created by the program, to trace the data objects in the heap so as to mark the data objects that are reachable at a given stage in the program, to loop over the mutator threads so as to verify for each of the mutator threads that every update to the allocated portions of the memory in progress by the mutator thread has been completed, and to sweep the heap so as to free the memory that is allocated to the data objects that are not marked as reachable, for reallocation to new data objects.
-
-
25. A computer software product, comprising a computer-readable medium in which code instructions are stored, which instructions, when read by a computer having a memory, cause the computer to allocate respective portions of the memory to data objects using mutator threads of a program in execution by the computer, whereby the objects are held in a heap created by the program, and further cause the computer to trace the data objects in the heap so as to mark the data objects that are reachable at a given stage in the program, to loop over the mutator threads so as to verify for each of the mutator threads that every update to the allocated portions of the memory in progress by the mutator thread has been completed, and to sweep the heap so as to free the memory that is allocated to the data objects that are not marked as reachable, for reallocation to new data objects.
Specification