Re: [Python-Dev] generic async io (was: microthreading vs. async io)
Greg Ewing <greg.ewing@canterbury.ac.nz> wrote:
An I/O operation passes a buffer, length, file and action and receives a token back.
You seem to be using the word "threading" in a completely different way than usual here, which may be causing some confusion.
Not really, though I may have been unclear again. Here is why that approach is best regarded as a threading concept: Perhaps the main current approach to using threads to implement asynchronous I/O operates by the main threads doing just that, and the I/O threads transferring the data synchronously. The reason that a token is needed is to avoid a synchronous data copy that blocks both threads. My general point is that all experience is that asynchronous I/O is best done by separating it completely from threads, and defining a proper asynchronous but NOT threaded interface. Regards, Nick Maclaren, University of Cambridge Computing Service, New Museums Site, Pembroke Street, Cambridge CB2 3QH, England. Email: nmm1@cam.ac.uk Tel.: +44 1223 334761 Fax: +44 1223 334679
participants (1)
-
Nick Maclaren