IP Library › Patent Application 13563221
Patent Application
App. No. 13/563,221

GARBAGE COLLECTION OF AN OBJECT

Loading inventors, assignments & file history…
Monitor This Case
Get email alerts when status or documents change.
Order Certified Copies
Most orders are placed with the USPTO same day — all within 24 business hours.
Order via The Patent Place →
Pre-filled with this patent's details
Quick Facts
Patent No.
US None
App. No.
13/563,221
Abstract

One or more embodiments are directed to creating a structure comprising a weak reference to an object, a strong reference to the object, a count of remote references to the object, and an identifier for the object, incrementing the count when a remote reference is created to the object and decrementing the count when a remote reference is removed, setting the strong reference in response to the count being greater than a first threshold in order to avoid a garbage collection of the object, clearing the strong reference in response to the count being less than a second threshold to enable a garbage collection of the object, and removing the structure and related resources based on a recognition of the object's collection through the weak reference.

Claims (30)

1 . An apparatus for performing garbage collection comprising:

at least one processor; and

memory having instructions stored thereon that, when executed by the at least one processor, cause the apparatus to:

create a structure comprising: a weak reference to an object, a strong reference to the object, a count of remote references to the object, and an identifier for the object,

increment the count when a remote reference is created to the object and decrement the count when a remote reference is removed,

set the strong reference in response to the count being greater than a first threshold in order to avoid a garbage collection of the object,

clear the strong reference in response to the count being less than a second threshold to enable a garbage collection of the object, and

remove the structure and related resources based on a recognition of the object's collection through the weak reference.

2 . The apparatus of claim 1 , wherein the first threshold is equal to zero and wherein the second threshold is equal to one.

3 . The apparatus of claim 1 , wherein the instructions, when executed by the at least one processor, cause the apparatus to:

store a first link to the structure to enable a lookup of the identifier based on the weak reference, and

store a second link to the structure to enable a lookup of the structure based on the identifier.

4 . The apparatus of claim 3 , wherein the first link is associated with a first table that maps a plurality of structures to a corresponding plurality of unique identifiers, and wherein the second link is associated with a second table that maps the plurality of unique identifiers to the plurality of structures.

5 . The apparatus of claim 1 , wherein the instructions, when executed by the at least one processor, cause the apparatus to:

garbage collect the object based at least in part on a determination that the strong reference is cleared.

6 . The apparatus of claim 1 , wherein the instructions, when executed by the at least one processor, cause the apparatus to:

garbage collect the object using a local garbage collection mechanism.

7 . The apparatus of claim 6 , wherein the local garbage collection mechanism comprises a Java garbage collection mechanism.

8 . A system for performing garbage collection comprising:

a computing device configured to store an object and a structure, the structure comprising:

a weak reference to the object,

a strong reference to the object,

a count of remote references to the object, and

a unique identifier to the object;

the computing device is configured to garbage collect the object when the count of remote references is less than a first threshold and when the number of local references to the object in the computing device is less than a second threshold.

9 . The system of claim 8 , wherein the computing device is configured to increment the count of remote references when a remote reference to the object is created and decrement the count of remote references when a remote reference to the object is removed.

10 . The system of claim 8 , wherein the first threshold is equal to one, and wherein the second threshold is equal to one.

11 . The system of claim 8 , wherein the computing device is configured to garbage collect the object via a distributed programming language running on Java virtual machines without modifying the Java.

12 . The system of claim 11 , wherein the distributed programming language comprises X10 programming language.

13 . The system of claim 8 , wherein the computing device comprises at least one of a personal computer, a laptop computer, a mobile device, and a server.

Assignments (1)
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Jul 31, 2012
From: ONODERA, TAMIYA; KAWACHIYA, KIYOKUNI
To: INTERNATIONAL BUSINESS MACHINES CORPORATION
Reel/Frame 028689/0928 →