Python's biggest compromises
daniel.dittmar at sap.com
Fri Aug 1 15:09:43 CEST 2003
Michael Hudson wrote:
> <button nature="hot">
> Reference counting *is* a form of garbage collection.
> Saying "Ref. counting sucks, let's use GC instead" is a statement near
> as dammit to meaningless.
This statement is not meaningless because most programmers will correctly
identify GC in this context as something like mark-and-sweep, generation
see also: DOS sucks, let's use an operating system instead.
> current scheme's biggest drawback is its memory overhead, followed by
> the cache-trashing tendencies of decrefs.
plus it doesn't support independent threads as all reference counting would
have to be protected, leading to poor performance.
But a lot of Python code depends on reference counting or more exactly it
depends on the timely call of the destructor. So even if a much better GC is
added to Python, reference counting would perhaps be kept for backwards
compatibility (see Python's biggest compromises)
More information about the Python-list