[ECOS] Thread states
Jonathan Larmour
jlarmour@redhat.com
Tue Jan 9 16:55:00 GMT 2001
Paleologos Spanos wrote:
>
> Hi,I have a question regarding the state of thread.
>
> -When a thread finishes its work what is its state? the "EXITED"?
> The question is if the "exited" state is showing that the thread has
> finished execution or it is the state after having exit(with the exit
> function) the thread?
The former - although from your description the latter would imply the
former anyway?
> -If I want to stop the execution of a thread and then start it again from
> the beggining again(not from the point it stopped) which
> are the appropriate functions? exit and then resume,or kill and then
> resume?
I think you are a bit confused: you call cyg_thread_exit() to exit the
calling thread; you call cyg_thread_kill() to request another thread exits.
When the thread exits you can call cyg_thread_resume() on it.
> -Will this thread be present on the wait_queue of the bitmap
> scheduler?(assuming that we have the bitmap scheduler)
At what point?
Jifl
--
Red Hat, Rustat House, Clifton Road, Cambridge, UK. Tel: +44 (1223) 271062
Un cheval, pas du glue. Pas du cheval, beaucoup du glue. || Opinions==mine
More information about the Ecos-discuss
mailing list