From: Michael A. <ya...@ya...> - 2009-09-17 16:34:37
|
> that only applies to I/O, as opposed to asynchronous operations in > general, such as mutex locking, sleeping, or any other user-defined > asynchronous operation. Yes and no. Yes, in that st_poll() does directly support waiting for I/O only. No, because other async operations can map to I/O by reading and writing a pipe or socketpair. For instance, user-defined lock functions could write something to a pipe whenever they lock or unlock a lock, and another thread could poll and read from the pipe to learn when such actions happen. This is how we recommend translating UNIX signals to I/O operations too; see http://state-threads.sourceforge.net/docs/notes.html |