PATCH: gcov: new option to merge results
Olivier Hainque
hainque@adacore.com
Fri Jun 8 16:55:00 GMT 2007
Tristan Gingold wrote:
> this patch adds a new option to gcov: --merge-results (-m).
> When this option is set, gcov reads all input files before writing
> results instead of writing results after each input file.
> Therefore, if two .gcda reference a common source file com.c, only
> one com.c.gcov file is generated with counts added rather than two
> com.c.gcov, the second one overwriting the first one.
Sounds like a significant behavior improvement, avoiding confusion if not
just wrong results in various contexts for different languages (Ada generics
come to mind, maybe inlining in general, C++ templates as well).
Do you have concrete examples of problems that prompted this change ?
Looks like this could even be the default behavior IMO.
More information about the Gcc-patches
mailing list