gcov for MIPS

Hi,

I find that gcov is very good Code Coverage tool if the compiler, gcov and the files required for gcov are generated in the same Host PC. But, i have a MIPS processor based board. The code is initially cross-compiled in the Host PC using the MIPS based cross-compiler. I executed the binary in the Board (Hardware). Will the files necessary for gcov be generated during the execution of the executable ?

Thx in advans, Karthik Balaguru

Reply to
karthikbalaguru
Loading thread data ...

After takin' a swig o' grog, karthikbalaguru belched out this bit o' wisdom:

Try it and see for yourself!

--
If you stand on your head, you will get footprints in your hair.
Reply to
Chris Ahlstrom

I posted that query in a simplified manner assuming that the method that is followed in any MIPS hardware board w.r.t gcov should be same and applicable for similar MIPS processor based boards.

The reason for the query is, i am unable to check if the files are generated.

I am using Octean CN5860 along with mipsisa64-octeon-elf-gcov and mips64-octeon-linux-gnu-gcc.

The application is a pure SE application running on a single core and so there is no Linux. Currently

Host PC - mips64-octeon-linux-gnu-gcc -fprofile-arcs -ftest-coverage sampleSE.c Target Board - execute sampleSE.elf Host PC - mipsisa64-octeon-elf-gcov sampleSE.c But, mipsisa64-octeon-elf-gcov has no knowledge of the files generated in the target board based on MIPS.

I think, i need to check with those Octeon support guys.

Thx, Karthik Balaguru

Reply to
karthikbalaguru

That's for you to answer yourself.

_You_ decide what you have on your MIPS board: what OS (or none at all), what file system, what level of support for special GCC features in the startup code and runtime environment. gcov relies on run-time support. Functions are called and data manipulated and, come shutdown, they're written to files. Either your startup code supports all this, or it doesn't.

Reply to
Hans-Bernhard Bröker

ElectronDepot website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.