APG - ARM Programmers Guide
REF - Architecture Reference Manual
duration of operation? basic approach:
start = clock();
operation();
stop = clock();
overhead
precision
variability
measure multiple times:
loop N times:
start = clock();
operation();
stop = clock();
endloop;
inflate impact of operation:
start = clock();
loop N times:
operation();
endloop;
stop = clock();
additional overheads
experiment duration
real-time with fixed period X? naive approach:
loop:
sleep(X);
action();
endloop;
account for deviations from perfect timing:
target = clock();
loop:
target += X;
sleep(target - clock());
action();
endloop;
cache
instruction: