Re: FSCopyObjectAsync hogging the thread?
Re: FSCopyObjectAsync hogging the thread?
- Subject: Re: FSCopyObjectAsync hogging the thread?
- From: Jens Alfke <email@hidden>
- Date: Thu, 10 Jun 2010 16:41:59 -0700
On Jun 10, 2010, at 4:29 PM, Kevin Boyce wrote:
> Boy I'll say! I put the FSCopyObjectAsync call in its own thread, and it made no difference whatsoever. Apparently that call is completely useless, unless you want to totally lock up the computer for a second at a time. Which seems odd to me.
Um, I have trouble believing that. The OS is very good at multithreading. I think something’s not doing what you think it’s doing — maybe you’re somehow blocking your main thread waiting on the background thread to finish, or the background thread acquires some lock that the main thread also needs? Because the only way thread B can block thread A is if A explicitly waits for it, or A tries to get a shared resource that’s being hogged by B.
Try sampling your app or running Instruments on it.
—Jens_______________________________________________
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