This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: gcov trouble
- From: Margus Metskivi <Margus dot Metskivi at liewenthal dot ee>
- To: gcc at gcc dot gnu dot org
- Date: Fri, 08 Mar 2002 12:46:40 +0200
- Subject: Re: gcov trouble
- Organization: Liewenthal Electronics
- References: <3C8883FB.1738D3EE@liewenthal.ee>
Hi
In addition I have to mention that gcov -b file.cpp works if file.cpp DOES NOT
include any other .h files with using code from other parts of the project
except from including standard headers and using standard functions. So,
gcov can analyse the code used as basis for other parts of the project but not
the code in the top or in the middle of project hierarchy. Strange a bit.
Has anybody had the same experience?
Margus Metskivi
Margus Metskivi wrote:
>
> Hi
>
> Is there anybody who has a good experience with gcov coverage program?
> Here we have quite a big project with many .so libraries. Someway when
> compiling project files with parameters
> -ftest-coverage -fprofile-arcs gcov -b file.cpp doesn't work.
> file.da, file.bb and file.bbg files are in the same path with file.cpp but
> gcov -b file.cpp gives Aborted(core dumped) error.
>
> Debugging of gcov shows that real count of program "arcs" when executing
> cpp code does not match arc number written somewhere in .bb, .bbg files.
> It means: gcc writes the number of arcs found in .cpp (and in all include
> files) somewhere in .bb or .bbg but gcov finds more arcs when executing
> the code of .cpp and crashes.
> Are there any ideas how to make gcov work?
>
> Margus Metskivi