On Oct 1, 2008, at 9:17 AM, Ashley Clark wrote:
As for your crashes I think I can offer some advice. If you're not doingany mallocs then most likely you're passing objects back to your main thread through some shared space, possibly via contextInfo:
Yes -- this can be a problem. If the contextInfo of an object is a stored in a (void *) instance variable, then the collector will not scan that iVar and will not that field as a reference to the object.
You can use CFRetain/CFRelease to prevent collection when a reference to the object is stored into an unscanned location.
I've seen in my own GC programs using threads that occasionally thecollector (usually during high object usage) will collect objects that are in transit unless you CFRetain them in your thread before sending and then CFRelease them in the other thread once you've assigned them to a gc- edstorage variable.
This should only happen if the object is only referenced by unscanned memory. If there are references on any thread's stack, then the collector shouldn't touch the object (assuming the thread is registered with the collector). If you have a reproducible case where you think the object should not be collected, but is, please file a bug and send me the #.
b.bum
smime.p7s
Description: S/MIME cryptographic signature
_______________________________________________ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the moderators at cocoa-dev-admins(at)lists.apple.com Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to [EMAIL PROTECTED]