From: Jeff D. <jd...@ka...> - 2002-01-07 00:25:46
|
sh...@ti... said: > In my experience (as a user-level person), pipes have several > advantages, all related to being able to use poll()/select() on them. > These include being able to wait on more than one, being able to wait > on I/O at the same time, and being able to specify a timeout. None of these matter in the situation we are talking about. The current UML context switcher is basically this: write(to->thread.switch_pipe[1], &c, sizeof(c); read(from->thread.switch_pipe[0], &c, sizeof(c); The next process is sleeping in that read. The write wakes it up and it goes about its business. Meanwhile, the outgoing process goes into that read and waits to be woken up by some other process going to sleep and writing a byte into its pipe. So, there are no issues with being able to monitor multiple descriptors at once or being able to set timeouts. Jeff |