diff options
author | Victor Stinner <victor.stinner@gmail.com> | 2016-04-22 14:26:23 (GMT) |
---|---|---|
committer | Victor Stinner <victor.stinner@gmail.com> | 2016-04-22 14:26:23 (GMT) |
commit | f5c4b99034fae12ac2b9498dd12b5b3f352b90c8 (patch) | |
tree | 743fb9af0ea98b29e696aa920d4823d30acf483f /Doc/using | |
parent | 5439fc4901dbc7ab0fc0c8d2b2266e05d0019a92 (diff) | |
download | cpython-f5c4b99034fae12ac2b9498dd12b5b3f352b90c8.zip cpython-f5c4b99034fae12ac2b9498dd12b5b3f352b90c8.tar.gz cpython-f5c4b99034fae12ac2b9498dd12b5b3f352b90c8.tar.bz2 |
PyMem_Malloc() now uses the fast pymalloc allocator
Issue #26249: PyMem_Malloc() allocator family now uses the pymalloc allocator
rather than system malloc(). Applications calling PyMem_Malloc() without
holding the GIL can now crash: use PYTHONMALLOC=debug environment variable to
validate the usage of memory allocators in your application.
Diffstat (limited to 'Doc/using')
-rw-r--r-- | Doc/using/cmdline.rst | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/Doc/using/cmdline.rst b/Doc/using/cmdline.rst index c1c700c..49fe3a0 100644 --- a/Doc/using/cmdline.rst +++ b/Doc/using/cmdline.rst @@ -628,12 +628,11 @@ conflict. Set the family of memory allocators used by Python: * ``malloc``: use the :c:func:`malloc` function of the C library - for all Python memory allocators (ex: :c:func:`PyMem_RawMalloc`, - :c:func:`PyMem_Malloc` and :c:func:`PyObject_Malloc`). - * ``pymalloc``: :c:func:`PyObject_Malloc`, :c:func:`PyObject_Calloc` and - :c:func:`PyObject_Realloc` use the :ref:`pymalloc allocator <pymalloc>`. - Other Python memory allocators (ex: :c:func:`PyMem_RawMalloc` and - :c:func:`PyMem_Malloc`) use :c:func:`malloc`. + for all domains (:c:data:`PYMEM_DOMAIN_RAW`, :c:data:`PYMEM_DOMAIN_MEM`, + :c:data:`PYMEM_DOMAIN_OBJ`). + * ``pymalloc``: use the :ref:`pymalloc allocator <pymalloc>` for + :c:data:`PYMEM_DOMAIN_MEM` and :c:data:`PYMEM_DOMAIN_OBJ` domains and use + the :c:func:`malloc` function for the :c:data:`PYMEM_DOMAIN_RAW` domain. Install debug hooks: |