glossary.rst 8.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280
  1. .. _Glossary:
  2. --------
  3. Glossary
  4. --------
  5. This section of the manual presents brief definitions of acronyms and terms used
  6. by QEMU developers.
  7. Accelerator
  8. -----------
  9. A specific API used to accelerate execution of guest instructions. It can be
  10. hardware-based, through a virtualization API provided by the host OS (kvm, hvf,
  11. whpx, ...), or software-based (tcg). See this description of `supported
  12. accelerators<Accelerators>`.
  13. Board
  14. -----
  15. Another name for :ref:`machine`.
  16. Block
  17. -----
  18. Block drivers are the available `disk formats and front-ends
  19. <block-drivers>` available, and block devices `(see Block device section on
  20. options page)<sec_005finvocation>` are using them to implement disks for a
  21. virtual machine.
  22. CFI
  23. ---
  24. Control Flow Integrity is a hardening technique used to prevent exploits
  25. targeting QEMU by detecting unexpected branches during execution. QEMU `actively
  26. supports<cfi>` being compiled with CFI enabled.
  27. Device
  28. ------
  29. In QEMU, a device is a piece of hardware visible to the guest. Examples include
  30. UARTs, PCI controllers, PCI cards, VGA controllers, and many more.
  31. QEMU is able to emulate a CPU, and all the hardware interacting with it,
  32. including `many devices<device-emulation>`. When QEMU runs a virtual machine
  33. using a hardware-based accelerator, it is responsible for emulating, using
  34. software, all devices.
  35. EDK2
  36. ----
  37. EDK2, as known as `TianoCore <https://www.tianocore.org/>`_, is an open source
  38. implementation of UEFI standard. QEMU virtual machines that boot a UEFI firmware
  39. usually use EDK2.
  40. gdbstub
  41. -------
  42. QEMU implements a `gdb server <GDB usage>`, allowing gdb to attach to it and
  43. debug a running virtual machine, or a program in user-mode. This allows
  44. debugging the guest code that is running inside QEMU.
  45. glib2
  46. -----
  47. `GLib2 <https://docs.gtk.org/glib/>`_ is one of the most important libraries we
  48. are using through the codebase. It provides many data structures, macros, string
  49. and thread utilities and portable functions across different OS. It's required
  50. to build QEMU.
  51. Guest agent
  52. -----------
  53. The `QEMU Guest Agent <qemu-ga>` is a daemon intended to be run within virtual
  54. machines. It provides various services to help QEMU to interact with it.
  55. .. _guest:
  56. Guest
  57. -----
  58. Guest is the architecture of the virtual machine, which is emulated.
  59. See also :ref:`host`.
  60. Sometimes this is called the :ref:`target` architecture, but that term
  61. can be ambiguous.
  62. .. _host:
  63. Host
  64. ----
  65. Host is the architecture on which QEMU is running on, which is native.
  66. See also :ref:`guest`.
  67. Hypervisor
  68. ----------
  69. The formal definition of an hypervisor is a program or API than can be used to
  70. manage a virtual machine. QEMU is a virtualizer, that interacts with various
  71. hypervisors.
  72. In the context of QEMU, an hypervisor is an API, provided by the Host OS,
  73. allowing to execute virtual machines. Linux implementation is KVM (and supports
  74. Xen as well). For MacOS, it's HVF. Windows defines WHPX. And NetBSD provides
  75. NVMM.
  76. .. _machine:
  77. Machine
  78. -------
  79. QEMU's system emulation models many different types of hardware. A machine model
  80. (sometimes called a board model) is the model of a complete virtual system with
  81. RAM, one or more CPUs, and various devices. It can be selected with the option
  82. ``-machine`` of qemu-system. Our machine models can be found on this `page
  83. <system-targets-ref>`.
  84. Migration
  85. ---------
  86. QEMU can save and restore the execution of a virtual machine between different
  87. host systems. This is provided by the :ref:`Migration framework<migration>`.
  88. NBD
  89. ---
  90. The `QEMU Network Block Device server <qemu-nbd>` is a tool that can be used to
  91. mount and access QEMU images, providing functionality similar to a loop device.
  92. Mailing List
  93. ------------
  94. This is `where <https://wiki.qemu.org/Contribute/MailingLists>`_ all the
  95. development happens! Changes are posted as series, that all developers can
  96. review and share feedback for.
  97. For reporting issues, our `GitLab
  98. <https://gitlab.com/qemu-project/qemu/-/issues>`_ tracker is the best place.
  99. .. _softmmu:
  100. MMU / softmmu
  101. -------------
  102. The Memory Management Unit is responsible for translating virtual addresses to
  103. physical addresses and managing memory protection. QEMU system mode is named
  104. "softmmu" precisely because it implements this in software, including a TLB
  105. (Translation lookaside buffer), for the guest virtual machine.
  106. QEMU user-mode does not implement a full software MMU, but "simply" translates
  107. virtual addresses by adding a specific offset, and relying on host MMU/OS
  108. instead.
  109. Monitor / QMP / HMP
  110. -------------------
  111. The `QEMU Monitor <QEMU monitor>` is a text interface which can be used to interact
  112. with a running virtual machine.
  113. QMP stands for QEMU Monitor Protocol and is a json based interface.
  114. HMP stands for Human Monitor Protocol and is a set of text commands available
  115. for users who prefer natural language to json.
  116. MTTCG
  117. -----
  118. Multiple CPU support was first implemented using a round-robin algorithm
  119. running on a single thread. Later on, `Multi-threaded TCG <mttcg>` was developed
  120. to benefit from multiple cores to speed up execution.
  121. Plugins
  122. -------
  123. `TCG Plugins <TCG Plugins>` is an API used to instrument guest code, in system
  124. and user mode. The end goal is to have a similar set of functionality compared
  125. to `DynamoRIO <https://dynamorio.org/>`_ or `valgrind <https://valgrind.org/>`_.
  126. One key advantage of QEMU plugins is that they can be used to perform
  127. architecture agnostic instrumentation.
  128. Patchew
  129. -------
  130. `Patchew <https://patchew.org/QEMU/>`_ is a website that tracks patches on the
  131. Mailing List.
  132. PR
  133. --
  134. Once a series is reviewed and accepted by a subsystem maintainer, it will be
  135. included in a PR (Pull Request) that the project maintainer will merge into QEMU
  136. main branch, after running tests.
  137. The QEMU project doesn't currently expect most developers to directly submit
  138. pull requests.
  139. QCOW2
  140. -----
  141. QEMU Copy On Write is a disk format developed by QEMU. It provides transparent
  142. compression, automatic extension, and many other advantages over a raw image.
  143. qcow2 is the recommended format to use.
  144. QEMU
  145. ----
  146. `QEMU (Quick Emulator) <https://www.qemu.org/>`_ is a generic and open source
  147. machine emulator and virtualizer.
  148. QOM
  149. ---
  150. :ref:`QEMU Object Model <qom>` is an object oriented API used to define
  151. various devices and hardware in the QEMU codebase.
  152. Record/replay
  153. -------------
  154. :ref:`Record/replay <replay>` is a feature of QEMU allowing to have a
  155. deterministic and reproducible execution of a virtual machine.
  156. Rust
  157. ----
  158. `A new programming language <https://www.rust-lang.org/>`_, memory safe by
  159. default. There is a work in progress to integrate it in QEMU codebase for
  160. various subsystems.
  161. System mode
  162. -----------
  163. QEMU System mode provides a virtual model of an entire machine (CPU, memory and
  164. emulated devices) to run a guest OS. In this mode the CPU may be fully emulated,
  165. or it may work with a hypervisor such as KVM, Xen or Hypervisor.Framework to
  166. allow the guest to run directly on the host CPU.
  167. QEMU System mode is called :ref:`softmmu <softmmu>` as well.
  168. .. _target:
  169. Target
  170. ------
  171. The term "target" can be ambiguous. In most places in QEMU it is used as a
  172. synonym for :ref:`guest`. For example the code for emulating Arm CPUs is in
  173. ``target/arm/``. However in the :ref:`TCG subsystem <tcg>` "target" refers to the
  174. architecture which QEMU is running on, i.e. the :ref:`host`.
  175. TCG
  176. ---
  177. TCG is the QEMU `Tiny Code Generator <tcg>`. It is the JIT (just-in-time)
  178. compiler we use to emulate a guest CPU in software.
  179. It is one of the accelerators supported by QEMU, and supports a lot of
  180. guest/host architectures.
  181. User mode
  182. ---------
  183. QEMU User mode can launch processes compiled for one CPU on another CPU. In this
  184. mode the CPU is always emulated. In this mode, QEMU translate system calls from
  185. guest to host kernel. It is available for Linux and BSD.
  186. VirtIO
  187. ------
  188. VirtIO is an open standard used to define and implement virtual devices with a
  189. minimal overhead, defining a set of data structures and hypercalls (similar to
  190. system calls, but targeting an hypervisor, which happens to be QEMU in our
  191. case). It's designed to be more efficient than emulating a real device, by
  192. minimizing the amount of interactions between a guest VM and its hypervisor.
  193. vhost-user
  194. ----------
  195. `Vhost-user <vhost_user>` is an interface used to implement VirtIO devices
  196. outside of QEMU itself.