This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

ARMCL profile information

Hi,

I am trying to generate the Unit tests of an application i have developed to run on some ARM cores. I have defined the UT with unity but now I would like to run them on target and see code coverage.

I am using the VISION SDK from TI and the compiler ARMCL. I have seen, there is a compilation option "--gen_profile_info" to add instrumentation to the code in orden to generate the code coverage report.

I am trying to test this on an example from texas instruments included in the Vision SDK: bsp_examples_i2c

make PLATFORM=tda3xx-evm PROFILE=release BUILD_DEPENDANCY_ALWAYS=yes bsp_examples_i2c

and the compilation is described in the mk-file as follows:

armcl --gen_profile_info -ppd=$(DEPFILE).P $(_CFLAGS) $(INCLUDES) $(CFLAGS_DIROPTS) $(COMPILEMODE)  $<

I get no error during compilation but nothing happens. According to the theory with this compilation option a .pdat file shold be generated with the profile info.

Did anyone ever made a code coverage report using the ARMCL compiler and knows how to use this compilation option? Am I missing sth?

Thanks!

Javier

  • Javier Garcia24 said:
    According to the theory with this compilation option a .pdat file shold be generated with the profile info.

    That is incorrect.  The .pdat file is generated when you execute a program that is compiled with the --gen_profile_info.  Please see the section in the ARM compiler manual titled Using Feedback Directed Optimization.

    Thanks and regards,

    -George

  • Hi George,

    thanks for your answer.

    I have also run the application. I am testing this compilation option with an example of the vision SDK (bsp_examples_i2c). So in the makefile I have added "armcl --gen_profile_info ..." I have compiled and linked and generated a binary (.xem4).

    I have loaded this binary on the board with CCS Studio and ran the application but no .pdat file was generated... am I executing wrongly the application?

    Thanks
    Javier
  • The documentation states ...

    When the program completes, a run-time-support function writes the collected information into a profile data file called a PDAT file.

    If your program does not complete, and is stopped some other way, the collected information is not written out.  You can avoid this problem by explicitly calling the RTS function _TI_stop_pprof_collection .

    Thanks and regards,

    -George