On Wed, May 14, 2008 at 7:59 AM, Jeroen Brattinga <
[EMAIL PROTECTED]> wrote:

> Volatile means that a thread won't cache the (value of) a variable. So
> your making sure that every thread sees updates on that variable.
>
> The Volatile keyword DOES NOT provide protection against multiple
> read/writes from different threads! Synchronization, locks or atomic
> variables are still needed when this is an issue.


I agree.  The discussion was about *visibility*, which volatile helps.  If
you need proper synchronization, volatile is not necessarily a substitute.

Thanks,
Sangjin

Reply via email to