2

Anyone knows c++ code coverage tool usable under the following conditions:

  1. Target platform is PowerPC CPU inside Nintendo WII dev.kit, that runs custom embedded OS. The only way to exchange data with the PC is to use custom proprietary API (sorry for my NDA).

  2. Compiler is not Microsoft, not GCC, not even command line. Namely it's Metrowerks IDE (running on Windows, of course).

Thanks in advance!

Soonts
  • 20,079
  • 9
  • 57
  • 130
  • This question is not really answerable. You're only saying what you DON'T have but leave out what you have. What PowerPC? What embedded OS? What proprietary API? What compiler vendor? – Thorsten79 Aug 04 '09 at 11:55
  • Thorsten79: PowerPC-based "Broadway" processor inside Nintendo WII dev.kit http://en.wikipedia.org/wiki/Broadway_(microprocessor) Custom embedded OS, custom proprietary API (sorry for my NDA) Metrowerks IDE and compiler – Soonts Aug 04 '09 at 12:12
  • 1
    Do you mean statement coverage? Or are you looking for profile information (ie. cost of function in seconds)? – Richard Corden Aug 04 '09 at 12:29
  • Richard: Statement coverage. Even just list of the functions/methods, that has never been called during the test run, will be enough. – Soonts Aug 04 '09 at 13:09
  • Is stubbing an option? ie. can you provide your own basic implementation of any system calls that your current environment doesn't have so that you can run the program on your machine? Then you could use a tool (such as gcov if you were on linux) to provide you with coverage information? – Richard Corden Aug 04 '09 at 15:16
  • Richard: Good idea! However, I'm afraid it's not an option, since there're too many different syscalls to implement. The software I'm developing is a videogame, extensively working with 3D and audio hardware, reading data from wii-only controller.. Some of syscalls are so low level that you'll find yourself emulating the actual hardware. – Soonts Aug 05 '09 at 12:01

4 Answers4

2

Do you know about BullseyeCoverage. It is a commercial tool, which supports really big number of platforms and compilers. If you don't see you compiler you can write them an inquiry. I did not find the Metrowerks Compiler in the list.

Hope that helps,
Ovanes

ovanes
  • 5,483
  • 2
  • 34
  • 60
  • Yep. Today google found them for me, and I wrote them a message. BTW did you use it in the real life? Are you happy with it? I only used Rational PureCoverage, a few years ago, but it's windows/linux/unix only. – Soonts Aug 04 '09 at 14:24
  • Sorry for the delay. I once evaluated it for Windows and Linux. That seemed to me pretty straight forward. I did not use this tool afterwards in an automated build environment. – ovanes Aug 05 '09 at 18:51
1

See Cpp Test Coverage. This tool can be configured to collect data in embedded systems; you have to figure out how to export an array of bits from inside that system to an external file system, and if you can do that, it can show you precise test coverage.

Does the Metrowerks compiler have special syntax that is not ANSI standard?

Ira Baxter
  • 93,541
  • 22
  • 172
  • 341
  • Where should I see that? Google 1-st result: scientific article on ieeexplore.ieee.org, 2-nd result: "Code coverage" on wikipedia, 3-rd result: "CppTest" unit testing framework. Metrowerks has a few special #pragma's, but AFAIK it's ANSI compliant. – Soonts Aug 05 '09 at 11:49
  • Sorry, "Cpp Test Coverage" was supposed to be a link, but I bungled it. Fixed, now you can follow the link. – Ira Baxter Aug 05 '09 at 16:39
0

My shop has been using a customized version of Covtool. Perhaps that could be ported to your environment.

Fred Larson
  • 60,987
  • 18
  • 112
  • 174
  • It seams the Covtool relies on the fact you can hook after C preprocessor and before C++ compiler, optimizer and linker. The assumption is wrong in case of Metrowerks IDE. – Soonts Aug 05 '09 at 11:54
0

I have used Cantata. It works with Metroworks. It instruments your code so your application will no run at full speed. You just need rewrite the IO functions so output happens using the custom proprietary API.

Ira Baxter
  • 93,541
  • 22
  • 172
  • 341
Gerhard
  • 6,850
  • 8
  • 51
  • 81