BeCuriouzBeCuriouz

Learn something new every day

🐙 Open Source
🖥️

The program that pretends to be a whole computer

💡 QEMU emulates a full computer in software, letting one machine run operating systems built for completely different CPU architectures.

QEMU (Quick EMUlator) is an open-source program that imitates an entire computer in software — CPU, memory, disks, network card and all. Run it and you get a virtual machine: a guest operating system that believes it's sitting on real hardware, when in fact it's just another process on your host. Its killer trick is cross-architecture emulation — on an Intel laptop you can boot a disk image built for ARM, RISC-V, or even an ancient PowerPC Mac, because QEMU translates the guest's machine instructions into ones your real CPU understands.

That translation would be painfully slow if done naively, so QEMU uses a Tiny Code Translator (TCT/TCG) that converts blocks of guest instructions into native code on the fly and caches them. When the guest happens to share your host's architecture (x86 guest on an x86 host), QEMU can skip emulation entirely and hand the CPU work to a hardware accelerator like KVM on Linux — running almost at native speed. This is why QEMU is the quiet engine underneath much of the cloud and tools like Android Studio's emulator and many libvirt-based setups.

A surprising bit of history: QEMU was created largely by one person, Fabrice Bellard — the same prolific developer behind the FFmpeg multimedia project. The repo has accumulated over 130,000 commits since the early 2000s, and the GitHub page is explicitly just a mirror: real contributions go through mailing-list patches, an old-school workflow QEMU still proudly uses.