mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-07 01:33:56 -06:00
Fix IO performance regression in sparc
Replace signalfd with signal handler/pipe. There is no way to interrupt the CPU execution loop when a file descriptor becomes readable. This results in a large performance regression in sparc emulation during bootup. This patch switches us to signal handler/pipe which was originally suggested by Ian Jackson. The signal handler lets us interrupt the CPU emulation loop while the write to a pipe lets us avoid the select/signal race condition. Signed-off-by: Anthony Liguori <aliguori@us.ibm.com> git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5451 c046a42c-6fe2-441c-8c8c-71466251a162
This commit is contained in:
parent
235262cf36
commit
9e472e101f
9 changed files with 53 additions and 231 deletions
13
vl.c
13
vl.c
|
@ -7475,6 +7475,19 @@ static int ram_load(QEMUFile *f, void *opaque, int version_id)
|
|||
return 0;
|
||||
}
|
||||
|
||||
void qemu_service_io(void)
|
||||
{
|
||||
CPUState *env = cpu_single_env;
|
||||
if (env) {
|
||||
cpu_interrupt(env, CPU_INTERRUPT_EXIT);
|
||||
#ifdef USE_KQEMU
|
||||
if (env->kqemu_enabled) {
|
||||
kqemu_cpu_interrupt(env);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
}
|
||||
|
||||
/***********************************************************/
|
||||
/* bottom halves (can be seen as timers which expire ASAP) */
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue