On 08/13/2018 03:39 PM, daro...@o2.pl wrote: > Hello, After compilation of source code with flags -fprofile-arcs, > -ftest-coverage and -fdump-tree-cfg-graph-lineno i get file with extension > .cfg.dot which can be opened in graphviz, and files with extensions .gcda and > .gcno when the program is executed. With gcov those files can be converted to > coverage report with extension .gcov. Because control flow graph is created > during compilation number of executions (FREQ) and percentage at which each > branch is taken are equal to 0. Is there a way to update control flow graph > with information from any of the files created after execution like .gcov or > .gcda/.gcno? Thank you Best regards >
Yes, if you use -fprofile-use and -fdump-tree-optimized-graph, then you'll see counts and frequencies as being read from .gcda profile. Profile is read from file in following IPA pass: main.c.065i.profile. 'optimized' is last tree pass, should be usable for you. Feel free to ask any further questions. Martin