[issue38437] Set GC_DEBUG for debug builds of the interpreter

2019-10-10 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: Thanks Victor and Tim! -- ___ Python tracker ___ ___ Python-bugs-list mailing list

[issue38437] Set GC_DEBUG for debug builds of the interpreter

2019-10-10 Thread Pablo Galindo Salgado
Change by Pablo Galindo Salgado : -- resolution: -> fixed stage: -> resolved status: open -> closed ___ Python tracker ___ ___

[issue38437] Set GC_DEBUG for debug builds of the interpreter

2019-10-10 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: New changeset 320dd504ddf65efe946e6d1e89053ed2d7ebe1e9 by Pablo Galindo in branch 'master': bpo-38437: Activate GC_DEBUG when PY_DEBUG is set (GH-16707) https://github.com/python/cpython/commit/320dd504ddf65efe946e6d1e89053ed2d7ebe1e9 --

[issue38437] Set GC_DEBUG for debug builds of the interpreter

2019-10-10 Thread Tim Peters
Tim Peters added the comment: +1. This code got quite brittle when they decided to fit two pointers, a fat integer, and 3 flags into a struct with room for only the two pointers ;-) It's a mine field now. Enabling one of the few automated mine detectors is thoroughly sensible.

[issue38437] Set GC_DEBUG for debug builds of the interpreter

2019-10-10 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: > Under which condition can such list be corrupted? If someone is adding/modifiying the gc and calls any of the functions that set the gc flags like (PREV_MASK_COLLECTING). One example is that after calling move_unreachable(), the unreachable set has

[issue38437] Set GC_DEBUG for debug builds of the interpreter

2019-10-10 Thread STINNER Victor
STINNER Victor added the comment: Under which condition can such list be corrupted? -- ___ Python tracker ___ ___ Python-bugs-list

[issue38437] Set GC_DEBUG for debug builds of the interpreter

2019-10-10 Thread Pablo Galindo Salgado
Change by Pablo Galindo Salgado : -- stage: patch review -> versions: -Python 3.7, Python 3.8 ___ Python tracker ___ ___

[issue38437] Set GC_DEBUG for debug builds of the interpreter

2019-10-10 Thread Pablo Galindo Salgado
Change by Pablo Galindo Salgado : -- keywords: +patch pull_requests: +16292 stage: -> patch review pull_request: https://github.com/python/cpython/pull/16707 ___ Python tracker

[issue38437] Set GC_DEBUG for debug builds of the interpreter

2019-10-10 Thread Pablo Galindo Salgado
New submission from Pablo Galindo Salgado : While working on bpo-38379 I had to manually set the GC_DEBUG macro to 1 to activate the extra checks that 'validate_list' does. These checks are super useful to make sure all the gc lists used are consistent and in the expected state with the