To LUGNET HomepageTo LUGNET News HomepageTo LUGNET Guide Homepage
 Help on Searching
 
Post new message to lugnet.robotics.rcx.legosOpen lugnet.robotics.rcx.legos in your NNTP NewsreaderTo LUGNET News Traffic PageSign In (Members)
 Robotics / RCX / legOS / 43
42  |  44
Subject: 
Idle process
Newsgroups: 
lugnet.robotics.rcx.legos
Date: 
Sun, 7 Mar 1999 01:11:04 GMT
Viewed: 
1110 times
  
I am reworking parts of the task scheduler in tm.c, tm.h, et al.

I notice, reading the code, that there is an idle process which runs all
of the time.  There is a note in tm.c; "execi needs pd_idle".  It
appears to use it to locate the head of the process list.

If that is the extent of the need for the idle process, I don't think
that the mechanism that I have in mind is going to miss it if I remove
it.  I am pretty much tearing up the linked list stuff and redoing it.
All of the other stuff (stack manipulation, _tm_switcher, the process
state model, yield(), exit(), etc. is remaining the same.

What I hope to gain by doing this is better performance when several
processes (tasks, whatever) have the same priority.

Does anybody see anything that I might be overlooking?  Does anything
else depend on the idle process?  All it does is an endless loop of
sleeps.


--
No honest business is promoted by spam
with the possible exception of Hormel.



Message has 1 Reply:
  Re: Idle process
 
Hi Lou, the sleep instruction effectively shuts down the CPU until the next interrupt occurs. Thus, the idle process conserves battery power if no task wishes to run. I consider this a worthwile feature. If you can do this without a dedicated idle (...) (26 years ago, 8-Mar-99, to lugnet.robotics.rcx.legos)

10 Messages in This Thread:


Entire Thread on One Page:
Nested:  All | Brief | Compact | Dots
Linear:  All | Brief | Compact
    

Custom Search

©2005 LUGNET. All rights reserved. - hosted by steinbruch.info GbR