A
system call method and device, the method comprising: a kernel of a first
virtual machine receiving an interrupt instruction of a first process, the first process running in a
user space of a second
virtual machine, the kernel of the first
virtual machine running in a kernel space of the second virtual
machine, the second virtual
machine being configured to provide a running environment of the first virtual
machine, at this time, a CPU switching from a
user state to a kernel state; the kernel of the first virtual machine mapping a first address associated with the interrupt instruction to a second address, the kernel of the first virtual machine executing the interrupt instruction based on the second address, obtaining an interrupt
processing result, and sending the interrupt
processing result to the first process, at this time, the CPU switching from the kernel state to the
user state. Therefore, in the process of the first virtual machine calling the
system, the CPU only needs to switch between the kernel state and the
user state twice, thereby reducing the
privilege level overhead, the context switching overhead, and the
resource consumption of the CPU.