Debian Codegraph @

Doc/glossary.rst

raw
1 .. _glossary:
2
3 ********
4 Glossary
5 ********
6
7 .. glossary::
8
9 bytecode
10 Python source code is compiled into bytecode, the internal representation
11 of a Python program in the interpreter. The bytecode is also cached in
12 ``.pyc`` and ``.pyo`` files so that executing the same file is faster the
13 second time (recompilation from source to bytecode can be avoided). This
14 "intermediate language" is said to run on a :term:`virtual machine`
15 that executes the machine code corresponding to each bytecode.
16
17 CPython
18 The canonical implementation of the Python programming language. The
19 term "CPython" is used in contexts when necessary to distinguish this
20 implementation from others such as Jython or IronPython.
21
22 GIL
23 See :term:`global interpreter lock`.
24
25 global interpreter lock
26 The lock used by Python threads to assure that only one thread
27 executes in the :term:`CPython` :term:`virtual machine` at a time.
28 This simplifies the CPython implementation by assuring that no two
29 processes can access the same memory at the same time. Locking the
30 entire interpreter makes it easier for the interpreter to be
31 multi-threaded, at the expense of much of the parallelism afforded by
32 multi-processor machines. Efforts have been made in the past to
33 create a "free-threaded" interpreter (one which locks shared data at a
34 much finer granularity), but so far none have been successful because
35 performance suffered in the common single-processor case.
36
37 virtual machine
38 A computer defined entirely in software. Python's virtual machine
39 executes the :term:`bytecode` emitted by the bytecode compiler.
40