[issue29049] Lazy GC tracking frame

2017-09-18 Thread STINNER Victor
STINNER Victor added the comment: FYI this optimization triggered a bug in the tp_clear slot of ElementTree parsers, bug which was hidden for years in Python 3: bpo-31499. -- ___ Python tracker

[issue29049] Lazy GC tracking frame

2017-03-31 Thread Donald Stufft
Changes by Donald Stufft : -- pull_requests: +890 ___ Python tracker ___ ___

[issue29049] Lazy GC tracking frame

2016-12-26 Thread INADA Naoki
Changes by INADA Naoki : -- status: open -> closed ___ Python tracker ___ ___

[issue29049] Lazy GC tracking frame

2016-12-26 Thread Roundup Robot
Roundup Robot added the comment: New changeset 5f3ac68f34f2 by INADA Naoki in branch 'default': Issue #29049: Remove unnecessary Py_DECREF https://hg.python.org/cpython/rev/5f3ac68f34f2 -- ___ Python tracker

[issue29049] Lazy GC tracking frame

2016-12-26 Thread INADA Naoki
INADA Naoki added the comment: > It seems to me, that the part with Py_DECREF should be pushed to older > branches. PyCoro_New() and PyGen_NewWithQualName() steals f reference, and DECREF when error. So Py_DECREF is not needed when (gen == NULL). My patch was wrong. --

[issue29049] Lazy GC tracking frame

2016-12-26 Thread Roundup Robot
Roundup Robot added the comment: New changeset d6913acb31e3 by INADA Naoki in branch 'default': Issue #29049: Fix refleak introduced by f5eb0c4f5d37. https://hg.python.org/cpython/rev/d6913acb31e3 -- ___ Python tracker

[issue29049] Lazy GC tracking frame

2016-12-25 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: LGTM. It seems to me, that the part with Py_DECREF should be pushed to older branches. -- ___ Python tracker ___

[issue29049] Lazy GC tracking frame

2016-12-25 Thread Xiang Zhang
Xiang Zhang added the comment: I don't have time study the patches. But 29049-fix-generator-refleak.patch fixes the two test failures on my PC. :-) -- ___ Python tracker

[issue29049] Lazy GC tracking frame

2016-12-25 Thread INADA Naoki
Changes by INADA Naoki : Added file: http://bugs.python.org/file46038/29049-fix-generator-refleak.patch ___ Python tracker ___

[issue29049] Lazy GC tracking frame

2016-12-25 Thread Xiang Zhang
Xiang Zhang added the comment: On my PC, this patch also introduces two tests failure: FAIL: test_log_destroyed_pending_task (test.test_asyncio.test_tasks.CTask_CFuture_SubclassTests) -- Traceback (most recent call last):

[issue29049] Lazy GC tracking frame

2016-12-25 Thread Serhiy Storchaka
Changes by Serhiy Storchaka : -- status: closed -> open ___ Python tracker ___

[issue29049] Lazy GC tracking frame

2016-12-25 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Perhaps this change caused reference leaks: test_exceptions leaked [1227, 1227, 1227] references, sum=3681 test_exceptions leaked [342, 344, 344] memory blocks, sum=1030 test_capi leaked [6043, 6043, 6043] references, sum=18129 test_capi leaked [1715, 1717,

[issue29049] Lazy GC tracking frame

2016-12-24 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Ah, sorry. Then it LGTM. Do you have a microbenchmark that exposes a maximal effect of this change? -- ___ Python tracker

[issue29049] Lazy GC tracking frame

2016-12-24 Thread INADA Naoki
INADA Naoki added the comment: > Please wrap private functions in #ifndef Py_LIMITED_API/#endif. No problem. Whole Include/frameobject.h is wrapped by Py_LIMITED_API. -- ___ Python tracker

[issue29049] Lazy GC tracking frame

2016-12-24 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Please wrap private functions in #ifndef Py_LIMITED_API/#endif. -- nosy: +serhiy.storchaka ___ Python tracker ___

[issue29049] Lazy GC tracking frame

2016-12-24 Thread INADA Naoki
INADA Naoki added the comment: (Rietveld shows 500 error when replying.) > Minor style note: Use Py_REFCNT here to simplify? Fixed when committing. -- ___ Python tracker

[issue29049] Lazy GC tracking frame

2016-12-24 Thread Roundup Robot
Roundup Robot added the comment: New changeset f5eb0c4f5d37 by INADA Naoki in branch 'default': Issue #29049: Call _PyObject_GC_TRACK() lazily when calling Python function. https://hg.python.org/cpython/rev/f5eb0c4f5d37 -- nosy: +python-dev ___

[issue29049] Lazy GC tracking frame

2016-12-24 Thread INADA Naoki
Changes by INADA Naoki : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___

[issue29049] Lazy GC tracking frame

2016-12-22 Thread Josh Rosenberg
Changes by Josh Rosenberg : -- nosy: +josh.r ___ Python tracker ___ ___

[issue29049] Lazy GC tracking frame

2016-12-22 Thread INADA Naoki
Changes by INADA Naoki : Added file: http://bugs.python.org/file46000/default.json.gz ___ Python tracker ___

[issue29049] Lazy GC tracking frame

2016-12-22 Thread INADA Naoki
INADA Naoki added the comment: --enable-optimizations: $ ~/local/cpython/bin/pyperf compare_to -G default.json patched.json Slower (12): - pickle_dict: 42.0 us +- 0.2 us -> 42.9 us +- 0.2 us: 1.02x slower (+2%) - regex_dna: 228 ms +- 1 ms -> 233 ms +- 2 ms: 1.02x slower (+2%) - unpickle_list:

[issue29049] Lazy GC tracking frame

2016-12-22 Thread INADA Naoki
New submission from INADA Naoki: Don't _PyObject_GC_TRACK(frame) before using it. After evaluation is finished, do tracking only if refcnt is not one. result without --enable-optimization: $ ~/local/cpython/bin/pyperf compare_to default.json.gz patched.json.gz -G Slower (15): -