#18905: fix more leaks found in #18897
---------------------------+------------------------
       Reporter:  dimpase  |        Owner:
           Type:  defect   |       Status:  new
       Priority:  major    |    Milestone:  sage-6.8
      Component:  memleak  |   Resolution:
       Keywords:           |    Merged in:
        Authors:           |    Reviewers:
Report Upstream:  N/A      |  Work issues:
         Branch:           |       Commit:
   Dependencies:  #18897   |     Stopgaps:
---------------------------+------------------------

Comment (by SimonKing):

 I am afraid that #14058 (which now has a branch) does not suffice to fix
 the problem: GF(31) still can't be collected after creating its algebraic
 closure. However, the coercion model is not mentioned any longer. Instead,
 the reference goes via a weak value dictionary, which seems to be the
 polynomial ring cache.

 My guess:
 - There is some polynomial ring P over the base ring GF(31) that was
 constructed when creating the algebraic closure of GF(31).
 - There is only a weak reference to P from the polynomial ring cache (it
 is weak value dictionary). However, for a different reason there is a
 strong reference to P.
 - Hence, the entry for P in the weak value dictionary can not be freed. By
 consequence, the reference to the KEY of this entry, which is a STRONG
 reference to GF(31), can not be freed.
 - Thus, GF(31) can not be deallocated.

 The question is: How is there a strong reference to P? Perhaps there is a
 strong reference from GF(31) to P? Maybe via caching the algebraic
 closure, which references an element of P? This would be enough to keep P
 alive.

--
Ticket URL: <http://trac.sagemath.org/ticket/18905#comment:19>
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 unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/sage-trac.
For more options, visit https://groups.google.com/d/optout.

Reply via email to