The profile tool in CCS v4 is completely different from that in CCS v3.
I have searched the methods in the web. However, nothing is shown in the profile view.
Can someone give the detailed steps for me? Thank you very much.
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.
Summer,
The type of profiling you can do varies based on which device you are using. C6x simulators tend to offer the most profiling capabilities while C6x hardware has the least. The wiki topic below covers the basics on how to use the profiler:
http://processors.wiki.ti.com/index.php/Profiler
If you don't see anything listed in the profile setup tool then the only option available to you for your target may be the profile clock. The following topic discusses how to use the clock on C28x targets, however the information works for other devices as well.
http://processors.wiki.ti.com/index.php/Profiling_on_C28x_Targets
Regards,
John
John, Thank you very much.
I am using C6416 simulator. I have read the wiki topic on profiler. However, there is still something that I cannot figure out.
When I want to derive the cycles for some specific lines in the program, for example "puts("hello world!\n");" in the following program, I did the following steps.
First, set "Pause Profiling" at the first line of this program. Second, set "Resume Profiling" at the line of "puts("hello world!\n");" . Third, set "Pause Profiling" at the line of "#ifdef FILEIO".
These steps are learnt from the web. However, I don't know the reason of setting the first "Pause Profiling" at the first line, can you explain this for me?
Another question: where can I find the explaination of the terms in the Properties of each Activities in Profile Setup?
Thank you.
void main()
{
#ifdef FILEIO
int i;
char scanStr[BUFSIZE];
char fileStr[BUFSIZE];
size_t readSize;
FILE *fptr;
#endif
puts("hello world!\n");
#ifdef FILEIO
/* clear char arrays */
for (i = 0; i < BUFSIZE; i++)
{
scanStr[i] = 0; /* deliberate syntax error */
fileStr[i] = 0;
}
/* read a string from stdin */
scanf("%s", scanStr);
........
Summer,
The reason for putting the pause at the beginning of your program is to stop the profiler otherwise it will be collecting data right from the beginning, you then put in a resume point where you want to start collecting again. For your use case I would put a breakpoint at the line you are interested in and one after the line you are interested in. Enable the profile clock. Run to the line. Clear the profile clock. Run to the next breakpoint and look at the value of the profile clock.
This topic explains more what the different events that you can profile are:
http://processors.wiki.ti.com/index.php/Simulator_Analysis_Event_Description
Regards,
John