There is no need to rearm the alarm timer when a qemu timer is deleted.
The current code contains a redundant rearm whenever qemu_del_timer() is used,
which is very often - in every qemu_mod_timer(). 
The rearm in qemu_mod_timer() is redundant because a currently-set timer
could not be brought forward due to delete - only postponed. And postponing the
timer is better done once in the end of qemu_run_timers().

Index: vl.c
===================================================================
RCS file: /sources/qemu/qemu/vl.c,v
retrieving revision 1.343
diff -u -p -r1.343 vl.c
--- vl.c        29 Sep 2007 19:24:40 -0000      1.343
+++ vl.c        1 Oct 2007 14:13:01 -0000
@@ -988,8 +988,6 @@ void qemu_del_timer(QEMUTimer *ts)
         }
         pt = &t->next;
     }
-
-    qemu_rearm_alarm_timer(alarm_timer);
 }
 
 /* modify the current timer so that it will be fired when current_time


Reply via email to