From: Pavel Dovgalyuk Date: Thu, 26 Jan 2017 12:34:18 +0000 (+0300) Subject: replay: exception replay fix X-Git-Tag: v2.9.0-rc2~173^2~35 X-Git-Url: https://git.proxmox.com/?a=commitdiff_plain;h=8499c8fca1ee9af86f1ad8d6daaddf053830aca2;p=mirror_qemu.git replay: exception replay fix This patch fixes replaying the exception when TB cache is full. It breaks cpu loop execution through setting exception_index to process such queued work as TB flush. v8: moved setting of exeption_index to tb_gen_code Signed-off-by: Pavel Dovgalyuk Message-Id: <20170126123418.5412.33815.stgit@PASHA-ISP> Signed-off-by: Paolo Bonzini --- diff --git a/translate-all.c b/translate-all.c index 20262938bb..6d2fcabca7 100644 --- a/translate-all.c +++ b/translate-all.c @@ -1290,6 +1290,8 @@ TranslationBlock *tb_gen_code(CPUState *cpu, /* flush must be done */ tb_flush(cpu); mmap_unlock(); + /* Make the execution loop process the flush as soon as possible. */ + cpu->exception_index = EXCP_INTERRUPT; cpu_loop_exit(cpu); }