The easiest way is as follows:
- Run the program in the debugger.
- And go to the debugger at some point.
- Look at the call stack, wherever you are.
- repeat steps 2-3
Doing this just two or three times gives you a very good idea of ββwhere most of your runtime is spent. If most of the execution time is spent on one function, then this function will be in the call stack almost every time you enter the debugger.
source share