4 ms·
Reference counting is very definitely a form of automatic memory management, aka GC. Every GC expert will disagree with your colloquial definition. There are tw
by barrkel 15y ago
Reference counting is very definitely a form of automatic memory management, aka GC. Every GC expert will disagree with your colloquial definition. There are two sides to every reference - the guy who has the pointer and the thing pointed to - and the most efficient GCs use a combination of both. The difference is that the "logical ref count" is distributed for mark-sweep etc, but centralized in object for refcounting.
- drewcrawford 15y agoWe're talking past each other. There's "Automatic reference counting, the dynamic garbage collection algorithm that runs periodically at runtime during your program's execution", and "Automatic reference counting, the static compile-time feature that ships in iOS5." These two things unfortunately share a name, but absolutely nothing else. The iOS 5 feature is not, and has no relationship to, and does nothing remotely like, the garbage collection algorithm with the same name.