On 09/28/2011 09:52 AM, Jan Kiszka wrote:
>  You can probably assume that qemu_notify_event (and dually the read in
>  the main loop) are resp. write/read memory barriers.  Or even full.
>
>  If we switch entirely to GSources, it would be nice to use them.  But
>  since we aren't, and our main loop functionality is quite different from
>  glib's (it doesn't rely on abstractions for file descriptors, for
>  example), it is just a painful incomplete transition to use glib's idle
>  sources to do the exact same thing that is done by bottom halves (which
>  are already in our toolbox).

BTW, I just wondered if there is anything conceptually preventing to
skip this ping pong between AIO thread and main loop and just run the
completion over the former context (under global lock protection of course).

Would be a good idea, but it would require some refactoring because tools do not have a global lock.

Paolo

Reply via email to