Re: GCD killed my performance
Re: GCD killed my performance
- Subject: Re: GCD killed my performance
- From: Quincey Morris <email@hidden>
- Date: Thu, 24 Apr 2014 23:16:14 -0700
On Apr 24, 2014, at 22:49 , Jens Alfke <email@hidden> wrote:
> It is, but most of it appears to be memory management _caused_ by GCD, since it goes away when I replace the dispatch calls with @synchronized. GCD is apparently causing a lot of blocks to get copied to the heap.
Well, you know what you’re seeing in Instruments, but this characterization seems improbable. Ignoring the GCD-specific entries, if block copy was causing a large number of retains and releases (if that’s what you meant by “refcount bookkeeping”), I’d expect there to be a large number of block copies, too. If block copies (as I’d also expect) are much more time-consuming than the retains/releases, by comparison you’d barely notice the retain/release times in Instruments. If the retains/releases caused by block copies do dominate, that suggests the block copies are comparatively very cheap, which in turn suggests a horrible bug in block copies.
With luck someone might jump in with a plausible answer, but this is starting to sound TSI-worthy.
_______________________________________________
Cocoa-dev mailing list (email@hidden)
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:
This email sent to email@hidden