[gprof] performance analysis
flag used: -pg
gcc -pg test.c
./a.out
gprof a.out > test
[gcov] code coverage
flag used: -ftest-coverage
gcc -ftest-coverage test.c
./a.out
gcov test.c
References:
http://blog.superd.org/index.php/2004/11/02/39/
http://codingfreak.blogspot.com/2009/02/gcov-analyzing-code-produced-with-gcc.html
沒有留言:
張貼留言