How to run QEMU without TCG and without KVM
Asked Answered
E

1

6

I'm trying to shut down a virtual core while my QEMU Virtual Machine is running.

For that purpose, I need to use the function qemu_cpu_kick() which is found at cpus.c:

void qemu_cpu_kick(CPUState *cpu)
{
    qemu_cond_broadcast(cpu->halt_cond);
    if (!tcg_enabled() && !cpu->thread_kicked) {
            qemu_cpu_kick_thread(cpu);
            cpu->thread_kicked = true;
    }
}

It works well - only if I enable KVM. However, I need to have KVM disabled, and once I disable KVM - the tcg_enabled() function returns true, and the cpu doesn't shut down.

Is it possible to disable TCG?

I didn't find any knob regarding TCG; --disable-tcg, as well as other trials, do not work. I tried to reconfigure my compilation with --disable-tcg-interpreter, but still nothing changes.

So, how can I disable TCG ? Or, alternatively - is there a better way to shut down a virtual cpu?

Thanks!

Eisenhower answered 16/12, 2015 at 19:35 Comment(0)
E
5

Well, as I understood, running QEMU without KVM forces QEMU to use the Tiny Code Generator (TCG) instead of KVM. So, running QEMU without KVM and without TCG is simply not possible!

Eisenhower answered 17/12, 2015 at 1:17 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.