GCspy downloads

GC Related links

People

University Links

GCspy: visualising the heap

GCspy screenshot

Deep understanding of program behaviour is essential to the design of the next generation of garbage collectors and explicit allocators. Until now no satisfactory tools have been available to assist the implementer in gaining an understanding of heap behaviour.

GCspy is an architectural framework for the collection, transmission, storage and replay of memory management behaviour. Its architecture allows easy incorporation into any memory management system: it is not limited to garbage-collected languages. It requires only small changes to the system in which it is incorporated but provides a simple to use yet powerful data-gathering API, that scales to allow very large heaps to be visualised effectively and efficiently. GCspy allows already-running, local or remote, systems to be visualised and those systems to run at full speed outside the points at which data is gathered. Its visualisation tool presents this information in a number of novel ways.

Installing, building and running GCspy

These notes assume you are using Linux.

  1. Download GCspy from http://www.cs.kent.ac.uk/projects/gc/gcspy/gcspy1_012.tar.gz. (The version at http://www.experimentalstuff.com/Technologies/GCspy/ is an old version.)
    Here is a history of changes.
     
  2. Download the Java Advanced Imaging (JAI) API from http://java.sun.com/products/java-media/jai/downloads/download-1_1_2.html. You want the download named "Linux CLASSPATH Install". You will pull down a file named jai-1_1_2-lib-linux-i586.tar.gz.
     
  3. Unpack the GCspy sources into a convenient place. Copy the JAI .jar files into your JDK's ext directory, e.g.:
    $ cp jai-1_1_2/lib/*.jar $JAVA_HOME/jre/lib/ext/
          
  4. You will need Java 5 (or later) to compile and run GCspy 1.0. Make the GCspy visualiser and server, e.g.:
    $ cd $GCSPY_ROOT/src/
    $ make install server java
          
    where server is either c or cpp, depending on whether you want the C or C++ server. Choose the C server if you are using GCspy with JikesRVM.
     
  5. Start your application, first having added the GCspy server library to your LD_LIBRARY_PATH
    $ export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$GCSPY_ROOT/src/server/lib
    $ my_application
          
  6. Then, start the GCspy visualiser:
    $ cd $GCSPY_CLASSES
    $ java gcspy.Main -server localhost 3000
          
    and click the "Connect" button in the bottom right-hand corner of the visualiser. (Alternatively, you can give the server and port arguments in the Connect dialogue box.)

Credits

GCspy is the product of an Memory Management Network collaboration between the universities of Glasgow (Tony Printezis, under a collaborative research agreement with Sun Microsystems Laboratories) and Kent (Richard Jones).

GCspy is freely available under an open source BSD-style license. An old version of GCspy is distributed by Sun Microsystems.

Screen shots can be found here.