POC certainly does create cycles. If reference counts *every* object
pointer. The only way to have an object pointer not count towards the
reference count of an object is to store it in a void*.
Notably its quite possible to build a GC which resolves cycles on top
of RC. AFAIK Python uses something similiar, one ObjC implementation is
available as part of libFoundation:
Its quite possible POC uses something similiar to resolve cycles.
But in general I can confirm the point about the AGC speed vs method
based reference counting. Though I have no hard numbers, libFoundation
with Boehm-GC "felt" quite a bit faster than with RC (though you need
to be quite careful when measuring stuff like this).
The drawback is really that it will always consume more memory (since
you always have dead objects hanging around until the next collection).
Whether or not this is an issue of course depends on the actual
application.
Anyway, all the pro's and contra's of ObjC GC can be read in almost any
ObjC newsgroup or mailing list archive. This was discussed meriads of
time, I'm rather interested what Tiger might bring here ;->
The only reason why we moved away from Boehm-GC is that it destroyed
portability/compatibility with Cocoa Foundation.
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Objc-language mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden