New Python 3.13 — Improved Performance and Multithreading

watch 1m, 12s
views 2

12:25, 10.10.2024

On October 7, 2024, the stable version of Python 3.13 was released, bringing many significant innovations, including an experimental JIT compiler, a mode without the Global Interpreter Lock (GIL), and an updated interactive interpreter based on PyPy. These improvements aim to enhance the performance and usability of the language. Python 3.13 will be supported for a year and a half, followed by security updates for an additional three and a half years.


One of the key new features is the experimental JIT compiler, which significantly accelerates program execution. To enable JIT in CPython, a build option --enable-experimental-jit has been added, requiring the installation of LLVM. This compiler operates on the Copy-and-Patch architecture, replacing bytecode with machine instructions in real time.


Another addition is the ability to build CPython without GIL. This feature, activated by the --without-gil option, enables parallel code execution on multi-core systems, addressing lock issues in multithreaded environments. However, disabling GIL slightly decreases performance for single-threaded programs, offset by gains in multithreading.


Another important improvement is the updated interactive interpreter, borrowing features from PyPy. It now supports multi-line editing, colored tracebacks, interactive help, and other enhancements for more convenient coding.


Python 3.13 also includes improved handling of local variables in functions and introduces a new typing.TypeIs annotation, and implements other notable changes, including an enhanced version of the mimalloc memory allocation library.

This release marks a significant step forward in Python's development, boosting its performance and opening new possibilities for multithreading and interactive programming.

Share

Was this article helpful to you?

VPS popular offers

-10%

CPU
CPU
8 Epyc Cores
RAM
RAM
32 GB
Space
Space
200 GB NVMe
Bandwidth
Bandwidth
Unlimited
Keitaro KVM 32768
OS
CentOS
Software
Software
Keitaro

77.54 /mo

/mo

Billed annually

-8.4%

CPU
CPU
4 Xeon Cores
RAM
RAM
2 GB
Space
Space
75 GB SSD
Bandwidth
Bandwidth
Unlimited
10Ge-wKVM-SSD 2048 Windows

37.4 /mo

/mo

Billed annually

-10%

CPU
CPU
6 Xeon Cores
RAM
RAM
16 GB
Space
Space
400 GB HDD
Bandwidth
Bandwidth
300 Gb
KVM-HDD HK 16384 Linux

39.15 /mo

/mo

Billed annually

-10%

CPU
CPU
4 Xeon Cores
RAM
RAM
2 GB
Space
Space
60 GB HDD
Bandwidth
Bandwidth
300 Gb
KVM-HDD HK 2048 Linux

6.09 /mo

/mo

Billed annually

-10%

CPU
CPU
4 Epyc Cores
RAM
RAM
4 GB
Space
Space
50 GB NVMe
Bandwidth
Bandwidth
Unlimited
wKVM-NVMe 4096 Windows

18.1 /mo

/mo

Billed annually

-24.7%

CPU
CPU
4 Xeon Cores
RAM
RAM
4 GB
Space
Space
50 GB SSD
Bandwidth
Bandwidth
4 TB
KVM-SSD 4096 Metered Linux

31 /mo

/mo

Billed annually

-9.5%

CPU
CPU
8 Xeon Cores
RAM
RAM
32 GB
Space
Space
200 GB SSD
Bandwidth
Bandwidth
Unlimited
wKVM-SSD 32768 Windows

73.99 /mo

/mo

Billed annually

-10%

CPU
CPU
4 Xeon Cores
RAM
RAM
2 GB
Space
Space
75 GB SSD
Bandwidth
Bandwidth
Unlimited
wKVM-SSD 2048 Windows

10.23 /mo

/mo

Billed annually

-9.7%

CPU
CPU
10 Epyc Cores
RAM
RAM
64 GB
Space
Space
300 GB NVMe
Bandwidth
Bandwidth
Unlimited
wKVM-NVMe 65536 Windows

139.49 /mo

/mo

Billed annually

-15.4%

CPU
CPU
4 Xeon Cores
RAM
RAM
4 GB
Space
Space
100 GB SSD
Bandwidth
Bandwidth
60 Mbps
DDoS Protected SSD-wKVM 4096 Windows

73 /mo

/mo

Billed annually

Other articles on this topic

Release of AlmaLinux 10.0
Release of AlmaLinux 10.0
cookie

Accept cookies & privacy policy?

We use cookies to ensure that we give you the best experience on our website. If you continue without changing your settings, we'll assume that you are happy to receive all cookies on the HostZealot website.