• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: FSCopyObjectAsync hogging the thread?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: FSCopyObjectAsync hogging the thread?


  • Subject: Re: FSCopyObjectAsync hogging the thread?
  • From: Kevin Boyce <email@hidden>
  • Date: Thu, 10 Jun 2010 19:29:20 -0400

 Greg Guerin wrote:

Kevin Boyce wrote:

Sure, it seems like it's just another dispatch from the runloop. Which would be fine if it copied like 100K bytes per invocation, or something like that. It seems instead to run off and copy vast quantities of data before returning. Copying a 4MB MP3 file actually completes before the first time anything else in the runloop gets any service. I was hoping I had just missed how to adjust the time slices it takes.


It may seem crazy, but there is no guarantee that any particular FS*Async function performs its operation asynchronously. The file- system operations could proceed entirely synchronously, and the only "asynchronous" part is that you get a callback at the end.

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.


There is certainly no way to specify time slices, or any other kind of slice or quantum, for the operation. If you want that granularity, you'll have to provide it yourself.

-- GG

Well maybe I should do that then!

-Kevin


_______________________________________________

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

_______________________________________________

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


  • Follow-Ups:
    • Re: FSCopyObjectAsync hogging the thread?
      • From: Jens Alfke <email@hidden>
References: 
 >Re: FSCopyObjectAsync hogging the thread? (From: Greg Guerin <email@hidden>)

  • Prev by Date: Re: Design Option: Exception handling vs Code Testing....
  • Next by Date: Re: Design Option: Exception handling vs Code Testing....
  • Previous by thread: Re: FSCopyObjectAsync hogging the thread?
  • Next by thread: Re: FSCopyObjectAsync hogging the thread?
  • Index(es):
    • Date
    • Thread