Sagi,  I suspect you are using the compiler with the SLES9 distro.  This compiler has some know problems.

In SLES9 SuSE modified the kernel as well as the gcc 3.3.3 compiler. The changes make it impossible to run a gcov-patched SLES9 kernel.  First, the SLES9-gcc has modifications to the GCOV structures used by the gcov-patch.  These changes are a mixture of gcc 3.3 and 3.4 structures.  This means that you can not compile a gcov-patched vanilla kernel with the SLES9 compiler,  Furthermore, the SLES9 kernel source can not compiled by a vanilla gcc compiler.

At this time we have no timetable for a gcov-patch fix.  

Let me know if this explanation does not fit your situation.


"Sagi Rotem" <>
Sent by:

10/03/2004 02:13 PM

        To:        <>
        Subject:        [LTP] Problem using gcov kernel patch 2.6.5

I had installed Suse 9.1 with kernel 2.6.5 and applied the patch.
The patch was downloaded today from the cvs.
during compilation of the kernel I had the following error.
 CC      init/version.o
 LD      init/built-in.o

 LD      .tmp_vmlinux1

init/built-in.o(.text+0x5c6): In function `global constructors keyed to envp_init_GCOV':

: undefined reference to `__gcov_init'

init/built-in.o(.text+0x5e6): In function `global constructors keyed to root_mountflags_GCOV':

: undefined reference to `__gcov_init'

init/built-in.o(.text+0x2266): In function `global constructors keyed to rd_prompt_GCOV':

: undefined reference to `__gcov_init'

init/built-in.o(.text+0x2276): In function `global constructors keyed to initrd_load_GCOV':

: undefined reference to `__gcov_init'

init/built-in.o(.text+0x2286): In function `global constructors keyed to md_run_setup_GCOV':

: undefined reference to `__gcov_init'

init/built-in.o(.text+0x3e26): more undefined references to `__gcov_init' follow

I had seen the problem reported by Jerone Young at 12/7/04 and a patch was delivered ?
Where can I find this patch ? is it already in the revision I has checked out today ?
Also does lcov support branch/function coverage data ? I had seen positive answers in the mail thread as well as negative ones.
thanks in advance,
Sagi Rotem