2021-01-18 10:13 AM
High level: I'm looking to improve the performance of our application and I need to work out which methods are consuming CPU time.
We have an application using NuttX as our RTOS running on STM32F777. The application is compiled with GCC using the NuttX build system based around make.
Our first problem is to track down performance in the network stack.
I'm looking for guidance on any tools or methods we can use to work out where the CPU time is going.
Ideally we would like to be able to do this without modifying the code. I know we can look at recording the cycle count on entering & exiting a method but given the size of the code base I would prefer not to have to do this.
Regards,
Mark
2021-01-18 11:55 AM
Hello @Nevyn ,
I suggest you the X-CUBE-32F7PERF STM32F7 performance software expansion for STM32Cube.
Please have a look at this AN4667 which provide guidelines and more details.
If my answer satisfy your need, please select it as Best by clicking on the "Select as Best" button, This will help other users find this solution more quickly.
Imen
2021-01-18 12:01 PM
Would your design permit attachment of a Trace Pod?
Instrumenting one's own code would seem like the least effort, highest payoff. Some compilers/tools permit the insertion of prologue/epilogue code.
Other scheme would be to monitor/record return address ranges for a high frequency interrupt. Get a quick heat-map for where it is spending time most.
2021-01-18 12:10 PM
>>I know we can look at recording the cycle count on entering & exiting a method but given the size of the code base I would prefer not to have to do this.
Automate it at the linker/build level, then you don't have to edit all the code.
2021-01-18 12:12 PM
2021-01-18 11:07 PM
Take a look on SEGGER SystemView:
https://www.segger.com/products/development-tools/systemview/
2021-01-24 06:49 AM
Thanks to you all for taking the time to assist, it is appreciated.
Our hardware is currently defined so the PDQ Logic could not be used - although I am going to keep a note of that for future designs.
I am currently investigating SystemView or a home built solution.
Again, many thanks for taking the time to respond.
Regards,
Mark