Forum Discussion
Altera_Forum
Honored Contributor
13 years agotimes() always returns 1 in NIOS II
Hi, I am trying to measure the process execution time using the following code... # include <stdlib.h># include "sys/alt_stdio.h"# include <sys/alt_alarm.h># include "sys/times.h"# inclu...
Altera_Forum
Honored Contributor
13 years agoHi,
thanks for your answers. In the end it was because the sys_clk_timer set to None in the BSP, now it is working. But on yet another different but related issue - the execution time of my statement is too short, even with very high amount of repeated executions using a for loop the execution time is less than one system clock tick, so that the measured result is not very useful. Does anyone know how to measure the execution time of a very fast statement? Thanks.