This is the mail archive of the ecos-discuss@sources.redhat.com mailing list for the eCos project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: R: Thread execution time


On Thu, Aug 28, 2003 at 11:24:22AM +0200, Michele Portolan wrote:
> What do you mean by "ticks"? Do yo mean clock cycles?

A tick is normally 10ms, but as with everything else in eCos, its
configurable.

> I am working on possible modifications of context-switching mechanism to
> implement fault tolerance funtionalities.
> I have just begun, there is not much yet, but I need these data as a
> comparison and make some "a priori" evaluation

Well 50ms round robin times and micro second context switches? There
are orders of magnitude differences here!

What sort of fault tolerance functionalities? IMHO, they don't make
much sense in an embedded system. You don't have a process context you
can clean up when something goes wrong. The thread could have all
sorts of mutex's locked, semaphores signaled, memory allocated
etc. Killing a thread will probably result in a deadlock sometime
later or memory exhortion. You just have a cascade of faults....

About the only fault tolerance functionality that makes sense to me is
"Something major has happened, lets try to do a controlled shutdown
and reboot before the watchdog timer reboot us anyway." The eCos
exception handling gives you enough to do this already.

         Andrew
> 
> Michele
> 
> > On Thu, Aug 28, 2003 at 10:54:19AM +0200, Michele Portolan wrote:
> > > Hi,
> > > how can I know the time quantum left by eCos to a thread, i.e. the time
> > > between two context switches?
> >
> > Im not sure i understand what you mean. Do you mean how long does a
> > thread run before it is round robin time sliced by another thread at
> > the same priority? By default a thread runs for five ticks. Its
> > controlled by CYGNUM_KERNEL_SCHED_TIMESLICE_TICKS.
> >
> > > Is there also a way to estimate the time needed by "load context" only
> and
> > > not complete context switch?
> >
> > What exactly are you trying to work out? What is the reason behind these
> > questions.
> >
> >         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
> 

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


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]