You can see the control flow graph of a function using gccjit;;function;;dump_to_dot():
func.dump_to_dot ("/tmp/sum-of-squares.dot");
giving a .dot file in GraphViz format.
You can convert this to an image using dot:
$ dot -Tpng /tmp/sum-of-squares.dot -o /tmp/sum-of-squares.png
or use a viewer (my preferred one is xdot.py; see
‘https://github.com/jrfonseca/xdot.py
’; on Fedora you can
install it with yum install python-xdot):
![]()
Figure