[Python-Dev] Marking GC details as CPython-only (original) (raw)
Maciej Fijalkowski fijall at gmail.com
Wed Feb 13 19:48:08 CET 2013
- Previous message: [Python-Dev] efficient string concatenation (yep, from 2004)
- Next message: [Python-Dev] Marking GC details as CPython-only
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Hi
I've tried (and failed) to find what GC details (especially finalizer semantics) are CPython only and which ones are not. The best I could find was the documentation of del here: http://docs.python.org/2/reference/datamodel.html
Things were pypy differs:
finalizers in pypy will be called only once, even if the object is resurrected. I'm not sure if this is detail or we're just plain incompatible.
pypy breaks cycles and runs finalizers in random order (but topologically correct), hence gc.garbage is always empty. I think this part is really just an implementation detail
we're discussing right now about running multiple finalizers. We want to run them in order, but if there is a link a -> b and a becomes unreachable, we want to reserve the right to call finalizer a then finalizer b, even if a.del resurrects a. What do you think?
Overall, the del is baaad.
Cheers, fijal
- Previous message: [Python-Dev] efficient string concatenation (yep, from 2004)
- Next message: [Python-Dev] Marking GC details as CPython-only
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]