#13896: Fix cython's gc_track and gc_untrack
------------------------------------------------------------------+---------
Reporter: nbruin |
Owner: rlm
Type: defect |
Status: needs_review
Priority: blocker |
Milestone: sage-5.6
Component: memleak |
Resolution:
Keywords: | Work
issues:
Report Upstream: Reported upstream. Developers acknowledge bug. |
Reviewers:
Authors: | Merged
in:
Dependencies: |
Stopgaps:
------------------------------------------------------------------+---------
Changes (by robertwb):
* status: new => needs_review
Old description:
> In a long sage-devel thread we eventually found
> [https://groups.google.com/group/sage-devel/msg/1d05a46b9b5fa8e2?hl=en in
> this message] that a GC during a weakref callback on a Cython class can
> lead to double deallocation of that class. In Python's
> [http://svn.python.org/projects/python/trunk/Objects/typeobject.c
> Objects/typeobject.c], line 1024 and onwards, there are some comments
> that indicate that earlier version of Python were bitten by this problem
> too. The solution is to insert the appropriate `PyObject_GC_Untrack` and
> `PyObject_GC_Track` in cython's deallocation code. This is best fixed in
> cython itself.
New description:
In a long sage-devel thread we eventually found
[https://groups.google.com/group/sage-devel/msg/1d05a46b9b5fa8e2?hl=en in
this message] that a GC during a weakref callback on a Cython class can
lead to double deallocation of that class. In Python's
[http://svn.python.org/projects/python/trunk/Objects/typeobject.c
Objects/typeobject.c], line 1024 and onwards, there are some comments
that indicate that earlier version of Python were bitten by this problem
too. The solution is to insert the appropriate `PyObject_GC_Untrack` and
`PyObject_GC_Track` in cython's deallocation code. This is best fixed in
cython itself.
Install only the new spkg at
http://sage.math.washington.edu/home/robertwb/patches/cython-0.17.4.spkg
--
Comment:
Spkg up at
http://sage.math.washington.edu/home/robertwb/patches/cython-0.17.4.spkg
--
Ticket URL: <http://trac.sagemath.org/sage_trac/ticket/13896#comment:24>
Sage <http://www.sagemath.org>
Sage: Creating a Viable Open Source Alternative to Magma, Maple, Mathematica,
and MATLAB
--
You received this message because you are subscribed to the Google Groups
"sage-trac" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/sage-trac?hl=en.