cpython/InternalDocs at main · python/cpython

python · GitHub

CPython Internals Documentation

The documentation in this folder is intended for CPython maintainers. It describes implementation details of CPython, which should not be assumed to be part of the Python language specification. These details can change between any two CPython versions and should not be assumed to hold for other implementations of the Python language.

The core dev team attempts to keep this documentation up to date. If it is not, please report that through the

issue tracker

.

General Resources

Source Code Structure

Compiling Python Source Code

Guide to the parser

Compiler Design

Changing Python's Grammar

Runtime Objects

Code Objects

Generators

Frames

Program Execution

The Bytecode Interpreter

Stack references (_PyStackRef)

The JIT

Garbage Collector Design

Exception Handling

Quiescent-State Based Reclamation (QSBR)

Stack protection

Built-in Types

String Interning

List sort algorithm

Modules

asyncio