• 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: Accuracy of timers?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Accuracy of timers?


  • Subject: Re: Accuracy of timers?
  • From: Scott Ribe <email@hidden>
  • Date: Thu, 23 Apr 2009 07:07:57 -0600
  • Thread-topic: Accuracy of timers?

> P.S. For completeness I should mention of course nanosleep, but I
> don't know of its precision and in any case it can be interrupted by
> signals, which makes it more difficult to use than you'd expect.

I use nanosleep in a non-main thread (when dealing with some twitchy USB
hardware that locks up if I send it commands too quickly), and I timed it
mostly out of curiosity. I found it to be shockingly accurate--sorry I don't
remember the numbers. Of course, I'm on an 8-core machine, and results may
well be very different on dual-core with a busy user...

--
Scott Ribe
email@hidden
http://www.killerbytes.com/
(303) 722-0567 voice


_______________________________________________

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

References: 
 >Re: Accuracy of timers? (From: Wade Tregaskis <email@hidden>)

  • Prev by Date: ESC while editing NSOutlineView subclass
  • Next by Date: Re: Accuracy of timers?
  • Previous by thread: Re: Accuracy of timers?
  • Next by thread: Re: Accuracy of timers?
  • Index(es):
    • Date
    • Thread