[analyzer] exploded-graph-rewriter: Open the converted graph immediately.

Authored by dergachev.a on Tue, Aug 13, 4:04 PM.


[analyzer] exploded-graph-rewriter: Open the converted graph immediately.

Change the default behavior: the tool no longer dumps the rewritten .dot file
to stdout, but instead it automatically converts it into an .html file
(which essentially wraps an .svg file) and immediately opens it with
the default web browser.

This means that the tool should now be fairly easy to use:

$ exploded-graph-rewriter.py /tmp/ExprEngine.dot

The benefits of wrapping the .svg file into an .html file are:

  • It'll open in a web browser, which is the intended behavior. An .svg file would be open with an image viewer/editor instead.
  • It avoids the white background around the otherwise dark svg area in dark mode.

The feature can be turned off by passing a flag '--rewrite-only'.
The LIT substitution is updated to enforce the old mode because
we don't want web browsers opening on our buildbots.

Differential Revision: https://reviews.llvm.org/D65250

llvm-svn: 368766