(旧文重发; early article)
When people mention “using a PC or a smart device”, they actually mean that they are using the operating system, such as Mac OS or Windows for PCs, Android or iOS for smart devices, etc.
So what about running an operating system under another, such as running a Windows under a Mac OS, or vice versa, like a Matryoshka doll?
The question actually entails two sub questions,
- Is it able to run nested operating systems?
- Is it able to run nested operating systems even under different instruction set architectures?
An instruction is a “command” that a CPU can execute (i.e., moves value from A to B, or adds values from A and B and stores result in A, etc.). An instruction set is all the “commands” that a CPU can execute. And an instruction set architecture includes the instruction set, as well as registers, addressing mode, etc. 1
- running nested operating systems
- running nested operating systems under different instruction set architectures (i.e., runs an Android system under a Windows or Mac OS of x86 architecture)
To achieve the purposes, essentially, Qemu translates one CPU instruction set to another dynamically.
(The article also in A Short Introduction to Qemu)