Options:
a) restore alarm timers (at least for the time being). Make all
alarm timers do qemu_notify_event. However, only run the AioContext
clock's timers within aio_poll. This is the least intrusive change.
b) calculate the timeout in aio_poll with respect to the minimum
deadline across all clocks, not just AioContext's clock. Use the
same logic in mainloop.
I'd go for (b), except for the millisecond accuracy thing. So my
temptation (sadly) is (a).
I think this is a non-issue because host_alarm_handler() can only be
called from the main loop:
main-loop.c:qemu_signal_init() sets up signalfd to monitor SIGALRM.
Therefore we do not asynchronously invoke the SIGALRM signals handler.
It is only invoked from main-loop.c:sigfd_handler() when the main loop
runs.
That's how I read the code. I haven't checked a running process to be
sure.