diff --git a/qemu/qom/cpu.c b/qemu/qom/cpu.c index 56a4e933..e107a105 100644 --- a/qemu/qom/cpu.c +++ b/qemu/qom/cpu.c @@ -172,13 +172,18 @@ static void cpu_common_reset(CPUState *cpu) cpu->exception_index = -1; cpu->crash_occurred = false; - for (i = 0; i < TB_JMP_CACHE_SIZE; ++i) { - atomic_set(&cpu->tb_jmp_cache[i], NULL); - } + // TODO: Should be uncommented, but good 'ol + // unicorn's crappy symbol deduplication + // makes it impossible right now + //if (tcg_enabled(cpu->uc)) { + for (i = 0; i < TB_JMP_CACHE_SIZE; ++i) { + atomic_set(&cpu->tb_jmp_cache[i], NULL); + } #ifdef CONFIG_SOFTMMU - tlb_flush(cpu, 0); + tlb_flush(cpu, 0); #endif + //} } static bool cpu_common_has_work(CPUState *cs)