]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
[2.7] bpo-31692: Add PYTHONSHOWALLOCCOUNT env var (GH-3927)
authorVictor Stinner <victor.stinner@gmail.com>
Tue, 17 Oct 2017 09:25:23 +0000 (02:25 -0700)
committerGitHub <noreply@github.com>
Tue, 17 Oct 2017 09:25:23 +0000 (02:25 -0700)
commit7b4ba62e388474e811268322b47f80d464933541
tree7d0ba89d476fe68d2d6901ed341e00ec8d43a9e6
parent3c082a7fdb472f02bcac7a7f8fe1e3a34a11b70b
[2.7] bpo-31692: Add PYTHONSHOWALLOCCOUNT env var (GH-3927)

bpo-31692, bpo-19527:

* Add a new PYTHONSHOWALLOCCOUNT environment variable, similar to
  the Python 3 "-X showalloccount" option
* When Python is compiled with COUNT_ALLOCS, the new
  PYTHONSHOWALLOCCOUNT environment variable now has to be set to dump
  allocation counts into stderr on shutdown. Moreover, allocations
  statistics are now dumped into stderr rather than stdout.
* Add @test.support.requires_type_collecting decorator: skip test if
  COUNT_ALLOCS is defined
* Fix tests for COUNT_ALLOCS: decorate some methods with
  @requires_type_collecting
* test_sys.test_objecttypes(): update object type when COUNT_ALLOCS
  is defined
Doc/c-api/typeobj.rst
Doc/using/cmdline.rst
Lib/test/support/__init__.py
Lib/test/test_abc.py
Lib/test/test_gc.py
Lib/test/test_regrtest.py
Lib/test/test_sys.py
Lib/test/test_weakref.py
Misc/NEWS.d/next/Core and Builtins/2017-10-09-11-03-13.bpo-31692.5-bpdk.rst [new file with mode: 0644]
Python/pythonrun.c