Can gcov be used to test multi-threaded application coverage?
I installed some trivial tests of our code base, but it would be nice to have an idea of ββthe coverage that we are achieving. If gcov is not suitable, someone might recommend an alternative tool (possibly an oprofile), ideally with good documentation at startup.
Of course, we used gcov to get coverage information for our multi-threaded application.
You want to compile with gcc 4.3, which can perform dynamic code coverage.
-fprofile-arcs -ftest-coverage, .gcda, gcov .
-fprofile-arcs -ftest-coverage
, .
, lcov HTML.
Gcov . , .
gcov lcov. .
lcov HTML- , .
gcov . MacOS Shark Apple . , .
http://developer.apple.com/tools/sharkoptimize.html