The pyperformance regex_compile benchmark is 1.17x slower on main than on 3.15 (1.19x on the free-threaded build). Bisecting points at the gh-152100 series (GH-152153, GH-152154, GH-152214). The regression is also visible on regex_compile on speed.python.org
regex_compile
The reason is redundant work in the case that no fusable constructs are present. Claude has several suggestions, one is in https://github.com/eendebakpt/cpython/tree/re-optimizer-skip-pass.
@serhiy-storchaka
CPython main branch
Linux
Activity