Re: Threading - How its done?
Re: Threading - How its done?
- Subject: Re: Threading - How its done?
- From: Scott Ribe <email@hidden>
- Date: Thu, 08 May 2008 09:33:50 -0600
- Thread-topic: Threading - How its done?
> What is sounds like you're saying is something like:
No, not exactly, because you know that str is constant and its value is set
at load time, so multiple readers without locks will be safe.
However, what he was responding to was much more broad, and not correct:
> Now if two threads are just reading the same piece of data it's ok
> for them to do so at the same time,
When was the data written? Unless you're dealing with const data, then you
still require synchronization primitives ON THE READS, to make sure that the
cache of the processor executing the reads is refreshed from main memory as
needed. Unless, of course, you know the exact details of the processor
you're running on and that this is not necessary.
--
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