This is the mail archive of the
mailing list for the GCC project.
A visualization of GCC's passes, as a subway map
- From: David Malcolm <dmalcolm at redhat dot com>
- To: gcc at gcc dot gnu dot org
- Cc: gcc-python-plugin at lists dot fedorahosted dot org
- Date: Mon, 11 Jul 2011 13:56:39 -0400
- Subject: A visualization of GCC's passes, as a subway map
For fun over the weekend I wrote a python script (using my
gcc-python-plugin) to render an SVG diagram of GCC's optimization
passes (or, at least, based on my understanding of them).
This diagram shows the various GCC optimization passes, arranged
vertically, showing child passes via indentation.
The lifetime of the various properties that they maintain is shown,
giving the pass that initially creates the data (if any), the pass that
destroys it (if any), and each pass that requires a particular property
(based on the PROP_* flags). I've attempted to make it look a little
like a subway train schematic map, where the properties are train lines,
and the passes are the stations they stop at; the initial/final passes
are the termini.
The resulting SVG can be seen at the top of:
Direct link to SVG, in case the above gets mangled on your browser:
(550 x 3302 pixels; about 250k in size).
The script can be seen here (it uses pycairo to abstract the drawing
Hope this is fun/helpful (and that I'm correctly interpreting the data!)