Scedular
Posted: Mon Apr 10, 2006 5:00 am
I've been thinking (I know it is a shock horror) about how to implement my schedular. Here is what i have come up with:
There is a link list of threads that are active. A thread is active when it is not waiting for a message(i.e. keyboard input, network communication, Window messages,etc..). The Timer interrupt cycles though the active threads and gives them a bit of cpu time. If a message is passed to a thread. the thread then is put in the active list ready for excution. if there are no processes in the active list the OS sleeps untill a thread becomes active.
Do you see any problems with this.
There is a link list of threads that are active. A thread is active when it is not waiting for a message(i.e. keyboard input, network communication, Window messages,etc..). The Timer interrupt cycles though the active threads and gives them a bit of cpu time. If a message is passed to a thread. the thread then is put in the active list ready for excution. if there are no processes in the active list the OS sleeps untill a thread becomes active.
Do you see any problems with this.