I want to measure/profile no of clock cycles takes to run a c++ code (say in cortex-M). How can I do this?
First read the Cortex-M3 manual and maybe "the_definitive_guide_to_arm_cortex_m3_and_cortex_m4". After reading you know the answer (and even more).
So why have you posted in the 'Classic Processors' forum?
View all questions in Classic processors forum