IBM®
Skip to main content
    United States change      Terms of use
 
 
Select a scope:    
     Home      Products      Services & industry solutions      Support & downloads      My account     
alphaWorks  >  Java technology  >  

HeapRoots

A tool for debugging memory leaks in Java applications through analysis of "heap dumps."


Date Posted: October 23, 2003
OverviewRequirements Download FAQs Forum Reviews

Update: November 30, 2005

A formal PHD release that should open all variants of the PHD file format up to and including IBM 1.4.2 SR3.

What is HeapRoots?

HeapRoots is a tool for debugging memory leaks in Java™ applications through analysis of "heap dumps."

The Java Virtual Machine (JVM) maintains a run-time data area (called a heap) for the allocation of all class instances and array objects. The heap storage for objects is automatically reclaimed by a storage management system known as the garbage collector. If an application requires more heap space than can be made available by the garbage collector, the JVM throws an OutOfMemoryError.

HeapRoots analyses "heap dumps," which are files (typically text files) containing information about the objects in the JVM garbage collected heap. Some IBM VMs (contained in the IBM Developer Kits for Windows®, Java Edition) have the ability to produce heap dumps on demand; heap dumps can also be triggered by out-of-memory situations.

How does it work?

HeapRoots loads these heap dump files and provides commands for analyzing the data. These commands run algorithms on the data or query for information about the data. HeapRoots provides a command-line interactive interface where one enters commands and gets results. Examples of analysis include the following:
  • searching/filtering of individual objects
  • summary/tabulation of the various types of objects
  • statistics on heap address space (such as gaps between objects)
  • inward and outward references of an object
  • paths between two objects
  • exploring the heap from source/root objects by following references
  • calculation of objects reachable by an object
  • calculation of objects kept alive by an object.


About the technology author(s):

David ScreenDavid Screen, a graduate in mathematics and computation, joined the service team of IBM's Java Technology Centre in December 2001. He currently works on the Process Automation (Build) team. He develops HeapRoots in his spare time because Java programming is fun and HeapRoots presents some tricky problems to solve.

Download now Download now

Related technologies

For platform(s):
Java

For topics:
analysis, debugging, garbage collection, JVM


Related resources

IBM Developer Kits

IBM Java SDK Diagnostics Guides

developerWorks Java zone

Java tutorials

Open source projects

JARS.com

 

    About IBM Privacy Contact