Hello, I'm trying to optimize some functions in ARM Cortex A9 architecture. Now, I want to judge whether the optimization is valid by reading and comparing the executed CPU cycles. But I can't find some tools in DS-5 to do this job. Could you give me some suggestion?
By default DS-5 is a time-based profile - so it takes samples of the program counter every 1ms, and over a period of many samples it can build up a statistical picture of what the program is doing, and where the CPU time is being spent. The tool doesn't report cycles - it reports load in each function as a percentage of runtime. If you optimize a function which was taking 5% of run-time and after modification it takes 2% of run-time then you have made it faster.
You get the best view of the data if you enable call chains (compile with -g -fno-omit-frame-pointer) and enable stack unwinding in the target configuration dialog of DS-5 Streamline.
Thanks. Very detailed and clear.
So, as you mentioned, DS-5 can't provide CPU cylces counter, could you konw any other ARM tools which can provide this function?