Created
November 4, 2023 00:01
-
-
Save MatzeB/9a578040fa0fe599ade7d9a6d9cb1766 to your computer and use it in GitHub Desktop.
Install cparser/libfirm and view a graph
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# CParser | |
$ git clone --recursive https://github.com/libfirm/cparser.git | |
$ cd cparser | |
$ make | |
$ cat ~/test.c | |
int foobar(int a, int b) { | |
return a + b; | |
} | |
$ build/debug/cparser -S -o - ~/test.c -fdump-all-phases | |
# This will create lots of *.vcg files in the current directory | |
# YComp graph viewer (Note: noncommercial/research use only!) | |
$ curl -L -O http://pp.ipd.kit.edu/firm/download/yComp-1.3.19.zip | |
$ unzip yComp-1.3.19.zip | |
$ cd yComp-1.3.19 | |
$ java -jar yComp.jar <my-graph.vcg> --dolayout --export <my-graph.svg> | |
$ open <my-graph.svg> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment