Claims
- 1. A method for determining deallocatable memory in a heap that includes a plurality of referenced objects, comprising:
determining a subset of objects based on a predetermined criterion; and determining the amount of deallocatable memory associated with objects of said subset.
- 2. The method as recited in claim 1, comprising removing reference cycles associated with said plurality of references of objects to provide an acyclic subset of objects.
- 3. The method as recited in claim 1, comprising performing a weighted memory calculation to approximate the amount of deallocatable memory held by the referenced objects.
- 4. The method as recited in claim 1, wherein the operation of determining a subset of objects comprises applying a filter criterion that includes a “Constrained Bytes Held” metric.
- 5. The method as recited in claim 1, wherein the operation of determining the amount of deallocatable memory associated with objects of the subset comprises temporarily removing the object and nullifying all the references to the particular object.
- 6. The method as recited in claim 1, wherein the referenced objects are associated with an object reference graph created pursuant to executing a software application that is written in a computer language selected from the group consisting of Java, Eiffel, and C#.
- 7. A computer-readable medium operable with a computer to determine deallocatable memory in a heap that includes a plurality of referenced objects, the medium having stored thereon:
instructions for determining a subset of objects based on a predetermined criterion; and instructions for determining the amount of deallocatable memory associated with objects of the subset.
- 8. The computer-readable medium as recited in claim 7, comprising instructions for removing reference cycles associated with said plurality of referenced objects to provide an acyclic subset of objects.
- 9. The computer-readable medium as recited in claim 7, comprising instructions for performing a weighted memory calculation to approximate the amount of deallocatable memory held by the referenced objects.
- 10. The computer-readable medium as recited in claim 7, wherein the instructions for determining a subset of objects comprise instructions for applying a filter criterion that includes a “Constrained Bytes Held” metric.
- 11. The computer-readable medium as recited in claim 7, wherein the instructions for determining the amount of deallocatable memory associated with objects of the subset comprise instructions for temporarily removing the object and nullifying all the references to the particular object.
- 12. The computer-readable medium as recited in claim 7, wherein the referenced objects are associated with an object reference graph created pursuant to executing a software application that is written in a computer language selected from the group consisting of Java, Eiffel, and C#.
- 13. A method for analyzing a heap for a subset of candidate lingering objects, comprising:
calculating the size of said heap; traversing said heap; for each object in said heap, removing reference cycles and performing a weighted memory calculation; applying a filter criterion to said objects to create a subset of candidate lingering objects; for each object in said subset of candidate lingering objects, temporarily removing said object and nullifying all references to that particular object; determining the amount of deallocatable memory associated with said object in said subset of candidate lingering objects; reinstantiating said object and its references; and presenting said subset of candidate lingering objects.
- 14. The method as recited in claim 13, wherein said operation of traversing said heap comprises traversing said heap in a recursive depth-first fashion.
- 15. The method as recited in claim 13, wherein said operation of performing a weighted memory calculation comprises performing a post-order weighted memory calculation.
- 16. The method as recited in claim 13, wherein said operation of determining the amount of deallocatable memory associated with said object comprises performing a garbage collection operation.
- 17. The method as recited in claim 13, wherein said operation of presenting said subset of candidate lingering objects comprises presenting said subset of candidate lingering objects via a user-interface.
- 18. The method as recited in claim 17, wherein said heap is associated with an execution of a software application in a development environment.
- 19. The method as recited in claim 17, wherein said heap is associated with an execution of a software application in a production environment.
- 20. A computer-readable medium operable with a computer to analyze a heap for a subset of candidate lingering objects, the medium having stored thereon:
instructions for calculating the size of said heap; instructions for traversing said heap; for each object in said heap, instructions for removing reference cycles and performing a weighted memory calculation; instructions for applying a filter criterion to said objects to create a subset of candidate lingering objects; for each object in said subset of candidate lingering objects, instructions for temporarily removing said object and nullifying all references to that particular object; instructions for determining the amount of deallocatable memory associated with said object in said subset of candidate lingering objects; instructions for reinstantiating said object and its references; and instructions for presenting said subset of candidate lingering objects.
- 21. The computer-readable medium as recited in claim 20, wherein said instructions for traversing said heap comprise instructions for traversing said heap in a recursive depth-first fashion.
- 22. The computer-readable medium as recited in claim 20, wherein said instructions for performing a weighted memory calculation comprise instructions for performing a post-order weighted memory calculation.
- 23. The computer-readable medium as recited in claim 21, wherein said instructions for determining the amount of deallocatable memory associated with said object comprise instructions for performing a garbage collection operation.
- 24. The computer-readable medium as recited in claim 22, wherein said instructions for presenting said subset of candidate lingering objects comprises instructions for presenting said subset of lingering objects in a user-interface.
- 25. The computer-readable medium as recited in claim 22, wherein said heap is associated with an execution of a software application in a development environment.
- 26. The computer-readable medium as recited in claim 22, wherein said heap is associated with an execution of a software application in a production environment.
- 27. A system for determining deallocatable memory in a heap that includes a plurality of referenced objects, comprising:
means for determining a subset of objects based on a predetermined criterion; and means for determining the amount of deallocatable memory associated with objects of said subset.
- 28. A computer, comprising:
a heap structure including a plurality of referenced objects; means for determining a subset of objects based on a predetermined criterion; and means for determining the amount of deallocatable memory associated with objects of said subset.
CROSS-REFERENCE TO RELATED APPLICATION(S)
[0001] This application discloses subject matter related to the subject matter disclosed in the following commonly owned co-pending patent application: “SYSTEM AND METHOD FOR OPTIMIZING MEMORY USAGE BY LOCATING LINGERING OBJECTS,” filed ______, Ser. No.: ______ (Docket Number 200208718-1), in the name of Piotr Findeisen, incorporated by reference herein.