aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authoraliguori <aliguori@c046a42c-6fe2-441c-8c8c-71466251a162>2008-10-31 18:40:25 +0000
committeraliguori <aliguori@c046a42c-6fe2-441c-8c8c-71466251a162>2008-10-31 18:40:25 +0000
commit0a1af395bc16a0ab42fbe5819a2fa73694740cd5 (patch)
tree98c66f1e6a792417075390a5f74d3cf8ec8ea3cd
parent56f3a5d01e435da0175e679d8a827d605a18e081 (diff)
downloadqemu-0a1af395bc16a0ab42fbe5819a2fa73694740cd5.zip
qemu-0a1af395bc16a0ab42fbe5819a2fa73694740cd5.tar.gz
qemu-0a1af395bc16a0ab42fbe5819a2fa73694740cd5.tar.bz2
Increase default IO timeout from 10ms to 5s
With the recent changes to the main loop, we no longer have unconditional polling. This means we can now sleep in select() for much longer than we previously did. This patch increases our select() sleep time from 10ms to 5s which is effectively unlimited since we're going to wake up sooner than that in almost all circumstances. With this patch, I see the number of wake-ups with an idle dynamic ticks guest drop from 80 per second to about 15 times per second. Signed-off-by: Anthony Liguori <aliguori@us.ibm.com> git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5578 c046a42c-6fe2-441c-8c8c-71466251a162
-rw-r--r--vl.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/vl.c b/vl.c
index 87ffb07..a443034 100644
--- a/vl.c
+++ b/vl.c
@@ -8182,7 +8182,7 @@ static int main_loop(void)
timeout = 0;
}
} else {
- timeout = 10;
+ timeout = 5000;
}
} else {
timeout = 0;
@@ -8192,7 +8192,7 @@ static int main_loop(void)
ret = EXCP_INTERRUPT;
break;
}
- timeout = 10;
+ timeout = 5000;
}
#ifdef CONFIG_PROFILER
ti = profile_getclock();