Open-Source Wikis

/

CPython

/

CPython

/

Glossary

python/cpython

Glossary

CPython has its own jargon on top of the language-level Python glossary. The terms below are the ones that appear most often in code comments, InternalDocs/, and PR discussion.

Term Meaning
Adaptive interpreter The default tier-1 bytecode interpreter (see Python/ceval.c) that rewrites instructions in place to specialized variants while running.
AST Abstract syntax tree. Defined by Parser/Python.asdl; generated C in Python/Python-ast.c.
bpo "bugs.python.org" — the legacy issue tracker. Issues now live on GitHub but old commits and comments still reference bpo-NNNNN IDs.
bytecodes.c DSL The little C-with-extensions language used in Python/bytecodes.c to define each opcode. Generators read it to emit the dispatch tables. See Tools/cases_generator/.
Argument Clinic The C function signature generator. .c files have a [clinic input] block describing parameter types and the tool emits the parsing wrapper. See Tools/clinic/.
CO_ flags Bitfield on a code object indicating capabilities (e.g. CO_GENERATOR, CO_COROUTINE, CO_VARARGS). See Include/cpython/code.h.
Code object / PyCodeObject Compiled bytecode + names + consts + line/column tables. Lives in Objects/codeobject.c.
DEOPT_IF / EXIT_IF Macros in Python/bytecodes.c used by specialized opcodes to bail out: DEOPT_IF resets to the unspecialized opcode; EXIT_IF exits a uop trace.
Devguide https://devguide.python.org/ — official process docs.
Free threading / nogil The build configuration without the GIL (PEP 703). Implementation in Python/ceval_gil.c (#ifdef Py_GIL_DISABLED) and Python/gc_free_threading.c.
Frame / _PyInterpreterFrame A single Python call activation: locals, instruction pointer, value stack. Lives in Objects/frameobject.c and Include/internal/pycore_frame.h.
GC Cycle collector for container objects (see Python/gc.c). Refcounting is separate.
gh-NNNNN A reference to GitHub issue/PR number in commit messages. The format gh-NNNNN: ... is enforced by Misc/NEWS.d machinery.
GIL The Global Interpreter Lock, implemented in Python/ceval_gil.c. One lock per interpreter (PEP 684) or per process (older builds).
HACL* The verified cryptographic library vendored under Modules/_hacl/. Provides hashlib digests independent of OpenSSL.
Inline cache Per-instruction memory used by specialized opcodes to remember the last shape they saw (e.g. type, dict version). The size per-opcode is in Lib/_opcode_metadata.py.
Interp Shorthand for PyInterpreterState. There can be many per process (subinterpreters).
JIT (tier 2) The optional copy-and-patch JIT enabled with --enable-experimental-jit. Code in Python/jit.c, stencils generated by Tools/jit/.
mimalloc Microsoft's small-object allocator vendored under Objects/mimalloc/. Used by free-threaded builds.
NEWS entry A file under Misc/NEWS.d/next/ describing a user-visible change. Created by blurb (see Tools/scripts/).
obmalloc The pymalloc small-object allocator in Objects/obmalloc.c.
opcode / oparg An 8-bit instruction code and 8-bit argument; together they form a _Py_CODEUNIT. Wider opargs use EXTENDED_ARG prefixes. See Interpreter.
PEG Parsing Expression Grammar. CPython's parser is a PEG parser since 3.9 (PEP 617). See Parser/parser.c.
PEP Python Enhancement Proposal. PEPs are the design-doc format that drives every cross-cutting language change.
PGO Profile-guided optimization. Enabled by ./configure --enable-optimizations.
Py_DECREF / Py_XDECREF Refcount macros in Include/refcount.h. The X variant tolerates NULL.
PyObject* The base pointer type all Python values are stored as. Layout in Include/object.h.
QSBR Quiescent-State Based Reclamation, used by the free-threaded build to defer freeing memory. Code in Python/qsbr.c.
Specialization The act of replacing a generic opcode with a type-specialized variant at runtime. See Python/specialize.c.
Stable ABI / limited API The subset of Python.h callable from extensions targeting future versions (Py_LIMITED_API). See Include/cpython/ for non-stable additions.
Stackref / _PyStackRef A "tagged" pointer type used by the value stack in the interpreter; carries deferred-refcount metadata. See Python/stackrefs.c and InternalDocs/stackrefs.md.
Tier 1 / Tier 2 Tier 1 = adaptive interpreter; tier 2 = micro-op (uop) trace executor or JIT. Used interchangeably with "interpreter" and "JIT" in newer code.
Tracelet / uop trace A sequence of micro-ops produced by the trace recorder for a hot loop. Optimized in Python/optimizer_analysis.c.
uop / μop "Micro-op" — a smaller, more uniform instruction used by tier 2. The IDs are in Include/internal/pycore_uop_ids.h.

Where this terminology lives in code

Built by Factory AutoWiki from public repository content. It is a generated preview for codebase exploration, not source-maintained documentation.

Glossary – CPython wiki | Factory