[ECOS] measure the execution time of each thread

Gary Thomas gary@mlbassoc.com
Tue Apr 19 11:07:00 GMT 2011


On 04/18/2011 05:32 PM, moktar_bouain wrote:
>
>
>> Note that this technique is only accurate to the system tick time
>> which is normally 10ms.  If your thread runs for less time than this,
>> you won't know.
>
>> Look at the test program tm_basic.cxx for details on how to measure
>> at a finer grain (without the overhead of decreasing the tick time).
>
> I use eCos for Sparc (Leon3 processor) with a 66 MHz.
> Means that the clock tick  corresponds to 1.5×10-5ms(15ns).
> is it possible  to measure the execution time of a thread??

That's not the "clock tick" that those functions are using, but the
hardware instruction clock.  The system clock is a periodic timer,
used to measure time, that normally runs at 100Hz

-- 
------------------------------------------------------------
Gary Thomas                 |  Consulting for the
MLB Associates              |    Embedded world
------------------------------------------------------------

-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss



More information about the Ecos-discuss mailing list