On Sunday, May 13, 2012 11:24:58 japplegame wrote:
> Does shared attribute automatic synchronization or should I do it
> manually?

shared does not automatically synchronize anything. It just means that the 
variable is shared across threads rather than being thread-local, and the 
compiler takes that into account with whatever optimizations and code 
generation it does. It does nothing to protect against multiple threads 
accessing it simultaneously.

- Jonathan M Davis

Reply via email to