Permalink
Please
sign in to comment.
Browse files
bpo-38858: Small integer per interpreter (GH-17315)
Each Python subinterpreter now has its own "small integer singletons": numbers in [-5; 257] range. It is no longer possible to change the number of small integers at build time by overriding NSMALLNEGINTS and NSMALLPOSINTS macros: macros should now be modified manually in pycore_pystate.h header file. For now, continue to share _PyLong_Zero and _PyLong_One singletons between all subinterpreters.
- Loading branch information
Showing
with
56 additions
and 37 deletions.
- +2 β2 Include/internal/pycore_pylifecycle.h
- +12 β0 Include/internal/pycore_pystate.h
- +5 β0 Misc/NEWS.d/next/Core and Builtins/2019-11-21-09-02-49.bpo-38858.bDLH04.rst
- +28 β31 Objects/longobject.c
- +9 β4 Python/pylifecycle.c
| @@ -0,0 +1,5 @@ | ||
| Each Python subinterpreter now has its own "small integer singletons": | ||
| numbers in [-5; 257] range. It is no longer possible to change the number of | ||
| small integers at build time by overriding ``NSMALLNEGINTS`` and | ||
| ``NSMALLPOSINTS`` macros: macros should now be modified manually in | ||
| ``pycore_pystate.h`` header file. |
0 comments on commit
630c8df