Coroutines vs. threads ought to have basically identical performance, GIL or no, since the I/O thread is always blocking on the command thread to complete, or the command thread is blocking on the I/O thread to provide input; either way there's only one thread running at a time. I could well believe that coroutines are ever so slightly more performant when written properly, just because you don't need to invoke the scheduler to allocate resources to the different threads, but I can't imagine it making a noticeable difference.
Put another way: we have far greater performance concerns.

Leave a comment: