On Thu, 2008-07-03 at 09:37 -0700, Robert Henry wrote: > I'm pondering some extension to gcov and its compile-time and run-time > support. > > I want to be able to run an unchanging instrumented victim binary > multiple times. Each time I run the victim binary I have a > unique invocation handle. The handle can be an integer; some client > of gcov and the driver can map integers to names. > > I'd like to add a 2nd column to the gcov statement profile output that > shows some invocation handle, where the handle is chosen from the > first (or last, or most frequent) victim invocation to execute the > statement. > > This way I can look at the statement profile output and determine > which invocation I should rerun in order to get some desired behaviour > out of the victim program. > > Case in point: the victim is gcc. The invocation handle is a hash of > the test program's name from some test suite. The question at hand is > "which test program causes gcc to execute this statement inside of > gcc?". > > Has anybody in the gcov developer community pondered or done such a thing?
I once helped with the development of some proprietary code coverage tools that let you keep multiple sets of data and get various combinations of them, or subtract one set from another, and then look at the results to find out which sets of tests covered which lines of code. I think we used environment variables to add prefixes or suffixes to the data files. Janis