unbale to generate crossgcc coverage
Iacaruso, Maurizio
maurizio.iacaruso@intel.com
Tue Jun 28 14:38:55 GMT 2022
Hi all,
I'm trying to collect the coverage of gcc compiler used to build zephyr SDK.
Here the source code of Zephyr SDK https://docs.zephyrproject.org/latest/develop/getting_started/index.html , https://github.com/zephyrproject-rtos/sdk-ng/releases/tag/v0.13.1 .
I'm using Zephyr SDK 0.13.1
NOTE: I'm interested in the coverage of crossgcc itself, not in the coverage of the source code built using gcc.
So I'm building the gcc toolchain enabling the coverage flags then I'm expecting to have the .gcda files generated when I run the gcc executable.
These are the steps I'm following:
1. I modified the x86_64-zephyr-elf.config adding following flags
* CT_BINUTILS_CFLAGS="-fprofile-arcs -ftest-coverage"
* CT_BINUTILS_LDFLAGS="-fprofile-arcs -ftest-coverage"
* CT_LIBC_NEWLIB_TARGET_CFLAGS="-fprofile-arcs -ftest-coverage"
* CT_LIBC_NEWLIB_CFLAGS="-fprofile-arcs -ftest-coverage"
* CT_GCC_CFLAGS="-fprofile-arcs -ftest-coverage"
* CT_GCC_LDFLAGS="-fprofile-arcs"
* CT_GCC_CXXFLAGS="-fprofile-arcs -ftest-coverage"
* CT_CC_CFLAGS="-fprofile-arcs -ftest-coverage"
* CT_CC_LDFLAGS="-fprofile-arcs"
* CT_CC_CXXFLAGS="-fprofile-arcs -ftest-coverage"
* CT_NEWLIB_NANO_CFLAGS="-fprofile-arcs -ftest-coverage"
2. I successfully build the SDK
3. I run the cross compiled GCC "gcc -h"
4. I'm expecting to have the .gcda files generated but there are no .gcda files.
Can someone help me?
Do you know how to generate the gcc coverage of cross-compiled gcc?
Thanks,
Maurizio
---------------------------------------------------------------------
INTEL CORPORATION ITALIA S.p.A. con unico socio
Sede: Milanofiori Palazzo E 4
CAP 20094 Assago (MI)
Capitale Sociale Euro 104.000,00 interamente versato
Partita I.V.A. e Codice Fiscale 04236760155
Repertorio Economico Amministrativo n. 997124
Registro delle Imprese di Milano nr. 183983/5281/33
Soggetta ad attivita' di direzione e coordinamento di
INTEL CORPORATION, USA
This e-mail and any attachments may contain confidential material for
the sole use of the intended recipient(s). Any review or distribution
by others is strictly prohibited. If you are not the intended
recipient, please contact the sender and delete all copies.
More information about the crossgcc
mailing list