Measuring execution time.

Comments

5 comments

  • Avatar
    Andrea

    Suggestion: if you don't want to (or can't) write specific code for the purpose, you can use the cycles counter (bottom right in the page, during debug).

    Set a break point when calling function, check the counter's value and then check it again when leaving function. Then divide by clock frequency and there you are.

    You can also reset the counter when entering (Target->Zero Cycle Counter).

    0
    Comment actions Permalink
  • Avatar
    Boikhutso

    Thanks for replying to the post/question.

    I thought I could be missing some sort of function time  profiling feature built-into the IDE.

    Many thanks for the suggestion.

    0
    Comment actions Permalink
  • Avatar
    Tero Koskinen

    Crossworks supports ITM/ETM/MTB and can also do PC sample based profiling. Check Trace options from solution/project settings (Target Trace / Trace Interface Type).

    Also, when debugging, open Execution Trace / Execution Profile windows (Ctrl+T T; Ctrl+T P).

    Of course, notice that if you are running RTOS, your functions might be constantly interrupted by systick / task switching.

     

    0
    Comment actions Permalink
  • Avatar
    Boikhutso

    Thank you very much Tero!

    0
    Comment actions Permalink
  • Avatar
    Szohar

    That is exactly what I was looking for, I can't find this in the current revision.

    Your help will be appreciated.

    Thanks

    0
    Comment actions Permalink

Please sign in to leave a comment.