I have written a library for ARMv8-A 64 bit processors (OS- linaro debian). Now I want to time them. I am utilising gcc compiler and on Intel processors I was timing the execution utilising std::chrono high resolution clock. The issue with arm is, it's quite volatile,. The timing difference between two different runs of the same executable can be significantly different.
You might want to try clock_gettime(CLOCK_REALTIME, ...).
An alternative is to directly read the system timer registers: cntpct_el0 / cntvct_el0.
The frequency of the system timer can be discovered by reading cntfrq_el0.
View all questions in Cortex-A / A-Profile forum