Python 3.11 introduced the Specializing Adaptive Interpreter. When the interpreter detects that some operations predictably involve the same types, those operations are “specialized.” The generic ...
Python -O won’t magically make every script faster, but in the right workloads it’s a free win—here’s how to test it safely.