gcov in conjunction with arm-elf-gcc

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi all,

finally we figured out the problem:
When compiling gcc for arm-elf targets the file _gcov.o is generated using 
the following line

/home/haidingerw/build-gcc/gcc/xgcc -B/home/haidingerw/build-gcc/gcc/ 
-B/usr/local/arm-elf/bin/ -B/usr/local/arm-elf/lib/ -isystem 
/usr/local/arm-elf/include -isystem /usr/local/arm-elf/sys-include -O2 
-DIN_GCC -DCROSS_COMPILE   -W -Wall -Wwrite-strings -Wstrict-prototypes 
-Wmissing-prototypes -Wold-style-definition  -isystem ./include 
-Dinhibit_libc -fno-inline -g  -DIN_LIBGCC2 -D__GCC_FLOAT_NOT_NEEDED 
-Dinhibit_libc -I. -I. -I../../gcc-3.4.3/gcc -I../../gcc-3.4.3/gcc/. 
-I../../gcc-3.4.3/gcc/../include   -DL_gcov -c 
../../gcc-3.4.3/gcc/libgcov.c -o libgcc/./_gcov.o

The problem is the define of "inhibit_libc" (-Dinhibit_libc), since this 
causes the generation of dummy functions.

==============================
/* file gcc/libgcov.c */
#if defined(inhibit_libc)
/* If libc and its header files are not available, provide dummy 
functions.  */

#ifdef L_gcov
void __gcov_init (struct gcov_info *p __attribute__ ((unused))) {}
void __gcov_flush (void) {}
#endif

#ifdef L_gcov_merge_add
void __gcov_merge_add (gcov_type *counters  __attribute__ ((unused)),
                       unsigned n_counters __attribute__ ((unused))) {}
#endif

#ifdef L_gcov_merge_single
void __gcov_merge_single (gcov_type *counters  __attribute__ ((unused)),
                          unsigned n_counters __attribute__ ((unused))) {}
#endif

#ifdef L_gcov_merge_delta
void __gcov_merge_delta (gcov_type *counters  __attribute__ ((unused)),
                         unsigned n_counters __attribute__ ((unused))) {}
#endif
==============================

Thus we draw the conclusion that coverage analysis in conjunction with 
arm-elf is not supported by the gcc.
Will there be a chance in the near future that gcc supports coverage 
analysis in conjunction with arm-elf targets?

Grüße
Wolfgang Haidinger
---
Wolfgang Haidinger
B&R Industrie-Elektronik GmbH
BU Controls, Safety
Tel: +43 (0)7748 6586 1121
eMail: wolfgang.haidinger@xxxxxxxxxxxxxxxxx


[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux