README revision 222
222N/AThe Ideal Graph Visualizer is a tool developed to help examine the
222N/Aintermediate representation of C2 which is commonly referred to as the
222N/A"ideal graph". It was developed in collaboration with the University
222N/Aof Linz in Austria and has been included as part of hotspot since that
222N/Awas the primary target of the tool. The tool itself is fairly general
222N/Awith only a few modules that contain C2 specific elements.
222N/A
222N/AThe tool is built on top of the NetBeans 6.0 rich client
222N/Ainfrastructure and so requires NetBeans to build. It currently
222N/Arequires Java 6 to run as it needs support for JavaScript for its
222N/Afiltering mechanism and assumes it's built into the platform. It
222N/Ashould build out of the box whit NetBeans 6 and Java 6 or later. It's
222N/Apossible to run it on 1.5 by including Rhino on the classpath though
222N/Athat currently isn't working correctly. Support for exporting graphs
222N/Aas SVG can be enabled by adding batik to the classpath which isn't
222N/Aincluded by default.
222N/A
222N/AIt can be built on top of NetBeans 6.1 if you change the required
222N/Amodules to be platform8 instead of platform7. The tool could run on
222N/AJDK 1.5 with some reworking of the how the JavaScript support is
222N/Aenabled but currently it requires some tweaking of the setup. This
222N/Awill be fixed in a later setup.
222N/A
222N/AThe JVM support is controlled by the flag -XX:PrintIdealGraphLevel=#
222N/Awhere # is:
222N/A
222N/A 0: no output, the default
222N/A 1: dumps graph after parsing, before matching, and final code.
222N/A also dumps graph for failed compiles, if available
222N/A 2: more detail, including after loop opts
222N/A 3: even more detail
222N/A 4: prints graph after parsing every bytecode (very slow)
222N/A
222N/ABy default the JVM expects that it will connect to a visualizer on the
222N/Alocal host on port 4444. This can be configured using the options
222N/A-XX:PrintIdealGraphAddress= and -XX:PrintIdealGraphPort=.
222N/APrintIdealGraphAddress can actually be a hostname.
222N/A
222N/AAlternatively the output can be sent to a file using
222N/A-XX:PrintIdealGraphFile=filename. Each compiler thread will get it's
222N/Aown file with unique names being generated by adding a number onto the
222N/Aprovided file name.
222N/A
222N/AMore information about the tool is available at
222N/Ahttp://wikis.sun.com/display/HotSpotInternals/IdealGraphVisualizer.