Talk:Profiling on the C6000 using Function Hooks

Comments on Profiling on the C6000 using Function Hooks -

Lehpat said ...
I had two issues with that application note:

1) The link "Associated example code and tool for this application note" seems not to be accessible by over public networks, however the 1st link in the abstract ("The example code and tool") works

2) The circular buffer does not work, because the buffer is only wrapped, when it is really full, so I had to patch that:

i.e. for entry hook: unsigned int uiOldGIE; //disable interrupt to make sure every record is atomic uiOldGIE= _disable_interrupts; uiProfileDataIndex &= (PROFILE_DATA_NUM-1); uiaProfileData[uiProfileDataIndex++]= (unsigned int)func_addr; uiProfileDataIndex &= (PROFILE_DATA_NUM-1); uiaProfileData[uiProfileDataIndex++]= TSCL; _restore_interrupts(uiOldGIE);  //restore interrupt uiProfileDataIndex &= (PROFILE_DATA_NUM-1);

--Lehpat 03:13, 31 August 2012 (CDT)

Camos said ...
I had the wrap issue too - just changing '<' to '<=' does the trick - classic.

It is also not too happy if it happens to task switch at the loop point, I just detected this, padded the last 2 entries with all Fs and put the task switch at the start of the loop.

--Camos 11:42, 27 September 2012 (CDT)

Brighton said ...
All known issue are fixed in the new 1.1.2 version. The key update include: 1.	Record TSCH+TSCL to avoid wrap-around, and to support raw data buffer as circular buffer 2.	Tasks loading statistics 3.	add Min and Max cycles statistics for functions and tasks. 4.	Add non-match record to function call history list. 5.	support parser the name of static functions. 6.	Record the configuration of last run. When you open the tool the next time, the configuration of last run will be automatically loaded.

--Brighton 01:51, 20 April 2013 (CDT)