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.

Restart OpenMP programs

Hello,

I introduced OpenMP in my program and recognized that the program was working correctly the first time, but a restart was not possible. In order to isolate the problem I stepped back to the example OpenMP 'matrix vector multiplication' which is part of CCS as you can see in the print screen below. I also attached the whole program.

6303.OpenMP_Example3.zip

When I execute this program the first time I get the following output:

Fig1: The program is executed correctly, but the question arises why the third last does not begin with the processor number?

This output is similar as decribed in this tutorial.

Question 1:

Why does not every line start with the number of the processor which printed the actual line (e.g. [C66xx_1])?

Question 2:

After I run the program the first time I press "Restart" and then "Resume" (I grouped the four cores). I expected that the program would execute a second time.

Sometimes this worked and the program is executed a second time, but often only a part is executed and sometimes nothing happened. Why is it not possible to execute the program several times?

Fig2: Console: Only two rows of the program were executed and then the program stopped. As you can see further, the Processor 1 status is "Suspended - SW Breakpoint2. Why that?

What I tried so far:

  • I added the gel file for every core in the target configuration file
  • I "Reset" all cores before doing a "Restart"
  • I made a 'System Reset' before the "Restart"

Every help is very appreciated!

Kind Regards,

Timon

Used configuration:

  • TMS320C6678
  • Windows 7
  • CCS: 5.3.0.00090
  • Compiler: 7.4.0
  • IPC: 1.25.0.04
  • MCSDK 2.01.02.05
  • System Analyzer (UIA Target) 1.00.03.25
  • Hi,

    Timon Achtnich said:

    Question 1:

    Why does not every line start with the number of the processor which printed the actual line (e.g. [C66xx_1])?

    The printf buffer may be flushing a bit out of sync with the Console view. I couldn't yet reproduce this here (so it can be thoroughly analyzed) but I will try to tweak a few things and see if I am able to do that.

    Timon Achtnich said:

    Question 2:

    After I run the program the first time I press "Restart" and then "Resume" (I grouped the four cores). I expected that the program would execute a second time.

    Sometimes this worked and the program is executed a second time, but often only a part is executed and sometimes nothing happened. Why is it not possible to execute the program several times?

    Many things can contribute to code being unable to run after a restart or reset, and they are usually tied to the way the core, clock and peripherals are initialized. For example, a code that initializes a peripheral but relies on some default values after reset may not work properly after a simple restart. In other scenario, a system that has several devices interconnected via busses (I2C, SPI, EMIF, etc.) will not have the same status as if powering up the board - therefore reseting just one device may cause some loss of sync or non-initialized devices.

    Hope this helps,

    Rafael