At the Python Language Summit during PyCon 2021, Guido van Rossum, the creator of the Python language, revealed ambitious plans aimed at significantly improving Python’s performance. The proposal outlines near-term and long-term goals that could see Python running anywhere from two to five times faster, and potentially even more. This announcement has sparked excitement within the Python community, as developers look forward to more efficient ways to execute Python code.
While there are already several ways to increase Python’s speed, such as using alternative runtimes like PyPy or wrapping modules in C/C++, most of these methods do not focus on improving CPython itself—the reference implementation of Python, which is written in C and remains the most widely used version. The new plan aims to address performance directly within CPython, ensuring it becomes faster without requiring external solutions.
In the short term, van Rossum and his team plan to introduce a major set of performance improvements in Python 3.11, which is currently under development and expected to be released in 2022. These improvements are expected to bring noticeable speed increases, but the challenge lies in making these changes without disrupting the stability of the language or breaking compatibility with existing Python code and extensions.
During his presentation, van Rossum emphasized that any changes made to CPython must meet strict constraints. For instance, modifications cannot break the runtime’s ABI (Application Binary Interface), ensuring that C extensions will continue to function as they currently do. The changes must also be incremental, maintaining the core principles of Python’s design, including its emphasis on readability and simplicity. Additionally, all performance improvements will be open source, in line with Python’s commitment to an open development process. Key areas identified for potential improvement include Python’s bytecode system, compiler, and interpreter, which are considered flexible enough to undergo significant changes.