public inbox for ecos-discuss@sourceware.org
 help / color / mirror / Atom feed
* [ECOS] Timing with longjmp
@ 2003-08-28 14:23 Michele Portolan
  2003-08-28 14:29 ` Andrew Lunn
  2003-08-28 14:29 ` Gary Thomas
  0 siblings, 2 replies; 5+ messages in thread
From: Michele Portolan @ 2003-08-28 14:23 UTC (permalink / raw)
  To: ecos-discuss

Is there a test in ecos2.0 release to measure the execution time needed by
"longjmp"?
If not, hwo can I do it (apart from counting assembler lines)?

Michele


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

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [ECOS] Timing with longjmp
  2003-08-28 14:23 [ECOS] Timing with longjmp Michele Portolan
@ 2003-08-28 14:29 ` Andrew Lunn
  2003-08-28 14:29 ` Gary Thomas
  1 sibling, 0 replies; 5+ messages in thread
From: Andrew Lunn @ 2003-08-28 14:29 UTC (permalink / raw)
  To: Michele Portolan; +Cc: ecos-discuss

On Thu, Aug 28, 2003 at 03:58:47PM +0200, Michele Portolan wrote:
> Is there a test in ecos2.0 release to measure the execution time needed by
> "longjmp"?

Not that i know off, but i've not gone looking.

> If not, how can I do it (apart from counting assembler lines)?

Use the ideas in tm_basic. It has the basic infrastructure to do the
measurements, you just need to write a test inside the framework.

        Andrew 

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

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [ECOS] Timing with longjmp
  2003-08-28 14:23 [ECOS] Timing with longjmp Michele Portolan
  2003-08-28 14:29 ` Andrew Lunn
@ 2003-08-28 14:29 ` Gary Thomas
  2003-08-28 14:52   ` [ECOS] R: " Michele Portolan
  1 sibling, 1 reply; 5+ messages in thread
From: Gary Thomas @ 2003-08-28 14:29 UTC (permalink / raw)
  To: Michele Portolan; +Cc: eCos Discussion

On Thu, 2003-08-28 at 07:58, Michele Portolan wrote:
> Is there a test in ecos2.0 release to measure the execution time needed by
> "longjmp"?
> If not, hwo can I do it (apart from counting assembler lines)?

There is not currently a test to time this.  If you look at the
code in 'tm_basic.cxx', you can get a pretty good idea how to measure
such [small] quantities.  Basically, you need to capture the current
raw clock time (tm_basic uses 'HAL_CLOCK_READ()' for this).  Grab the
value before doing the longjump and then after you land in the new
location.  Then it's just simple math to figure out how long it took.
Again, tm_basic can show you how to convert the values to real time
(micro-seconds or whatever).

Why are you bothering with such minutia?

-- 
Gary Thomas <gary@mlbassoc.com>
MLB Associates


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

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [ECOS] R: [ECOS] Timing with longjmp
  2003-08-28 14:29 ` Gary Thomas
@ 2003-08-28 14:52   ` Michele Portolan
  2003-09-02  2:44     ` Jonathan Larmour
  0 siblings, 1 reply; 5+ messages in thread
From: Michele Portolan @ 2003-08-28 14:52 UTC (permalink / raw)
  To: ecos-discuss

> There is not currently a test to time this.  If you look at the
> code in 'tm_basic.cxx', you can get a pretty good idea how to measure
> such [small] quantities.  Basically, you need to capture the current
> raw clock time (tm_basic uses 'HAL_CLOCK_READ()' for this).  Grab the
> value before doing the longjump and then after you land in the new
> location.  Then it's just simple math to figure out how long it took.
> Again, tm_basic can show you how to convert the values to real time
> (micro-seconds or whatever).
>
> Why are you bothering with such minutia?

I am making some peculiar timing measures on eCos to develop some idea, as I
said on a precedent post. That is the reason why I am so interested in such
little things: they could make the difference.

Michele


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

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [ECOS] R: [ECOS] Timing with longjmp
  2003-08-28 14:52   ` [ECOS] R: " Michele Portolan
@ 2003-09-02  2:44     ` Jonathan Larmour
  0 siblings, 0 replies; 5+ messages in thread
From: Jonathan Larmour @ 2003-09-02  2:44 UTC (permalink / raw)
  To: Michele Portolan; +Cc: ecos-discuss

Michele Portolan wrote:
>>There is not currently a test to time this.  If you look at the
>>code in 'tm_basic.cxx', you can get a pretty good idea how to measure
>>such [small] quantities.  Basically, you need to capture the current
>>raw clock time (tm_basic uses 'HAL_CLOCK_READ()' for this).  Grab the
>>value before doing the longjump and then after you land in the new
>>location.  Then it's just simple math to figure out how long it took.
>>Again, tm_basic can show you how to convert the values to real time
>>(micro-seconds or whatever).
>>
>>Why are you bothering with such minutia?
> 
> I am making some peculiar timing measures on eCos to develop some idea, as I
> said on a precedent post. That is the reason why I am so interested in such
> little things: they could make the difference.

Watch out for HAL_CLOCK_READ wrapping BTW.

Jifl
-- 
eCosCentric    http://www.eCosCentric.com/    The eCos and RedBoot experts
--["No sense being pessimistic, it wouldn't work anyway"]-- Opinions==mine


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

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2003-09-02  2:44 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-08-28 14:23 [ECOS] Timing with longjmp Michele Portolan
2003-08-28 14:29 ` Andrew Lunn
2003-08-28 14:29 ` Gary Thomas
2003-08-28 14:52   ` [ECOS] R: " Michele Portolan
2003-09-02  2:44     ` Jonathan Larmour

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).