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.

Cycles count using XDS100v1

Other Parts Discussed in Thread: OMAP-L138, TMS320C6748

Hello

I did some tests using the simulator "Texas Instruments Simulator" of CCS 4 to test the times of some functions of DSPLIB library, for example, IIR and FFT.

Now, I'm using a board "EVM Kit OMAP-L138" with the "TMS320C6748 SOM-M1" and I'm debugging the same project through the "Texas Instruments XDS100v1 USB Emulator".

Why the number of cycles between the two projects is different?  The difference is very great.  For example, the function "DSPF_sp_iir ()" in "Texas Instruments simulator" is runs in 9291 cycles and in Texas Instruments XDS100v1 USB Emulator "is performed in 218,102 cycles.

Is there any relation with the setting "Target-> Clock-> Setup"?  What is the difference between these options Clock Setup (Read Hit L1D, L1D Write Hit, cycle.CPU, etc.)?

Thanks

 

Rafael.

  • Hello Rafael,

    The simulator is executing in a best-case scenario whereas using an emulator on hardware is realistic and bound by the system traffic. For example, are you running the function in external memory with cache disabled? If so it is not out of the question to see a significant cycle count increase of ~20x as external SDRAM will run significantly slower than internal SRAM. The external SDRAM is running at a slower clock speed and,  perhaps more importantly, has a smaller bus width than the internal memory.

    I suggest making sure that all of your code is running inside internal memory rather than external memory.

  • 0131.Test5.zip

     

    Helo Tim.

    I have some questions to do.

    1) Which of the following memory (IRAM, CACHE_L1P, CACHE_L1D, L3_CBA_RAM or DDR) the DSP will have a better performance?

    2) If the code memory and data memory are running in the same memory, the performance of the DSP will be better?

    3) How do I select which memory I'll write my code?  I do this by DSPBIOS?

    4) It is possible in real scenario get the same performance of the simulator in at least some functions?

    Currently my project is running completely in the IRAM.

    My project is attached.

    Thanks

    Rafael.

     

  • In the attached project of previous post, when I run a line of code with the "Step Into (F5)" or "Step Over (F6)" these lines are executed in a number of cycles greater than if I run the "Run  To Line (Ctrl R) "or" Run (F8) "using a breakpoint.

    Why this difference occurs?

    Thanks

  • Rafael Werneck said:
    1) Which of the following memory (IRAM, CACHE_L1P, CACHE_L1D, L3_CBA_RAM or DDR) the DSP will have a better performance?

    Running directly from L1D/L1P will always yield the best results, but space is limited. IRAM is second best, then L3, and last but not least DDR.

    Rafael Werneck said:
    2) If the code memory and data memory are running in the same memory, the performance of the DSP will be better?
    In theory this shouldn't matter, but the faster the memory in which each is located the better.

    Rafael Werneck said:
    3) How do I select which memory I'll write my code?  I do this by DSPBIOS?
    Yes. Right click on the Memory Section Manager to place different code/data sections into different memory segments.

    Rafael Werneck said:
    4) It is possible in real scenario get the same performance of the simulator in at least some functions?
    This is generally difficult to see because a real-world application will always have more variables to account for than the simulator can take into account.