how to cast away 'volatile'?
Lawrence Crowl
crowl@google.com
Tue Mar 13 21:56:00 GMT 2007
On 13 Mar 2007 08:50:25 -0700, Ian Lance Taylor <iant@google.com> wrote:
> volatile doesn't help when sharing a memory buffer between threads
> because volatile carries no implication of a read/write memory
> barrier.
The C++ standards committee has adopted the same view; existing volatile
semantics will remain unchanged and there will be separate semantics for
communicating between threads. The C standards committee is only now
beginning to address these issues, and so (to my knowledge) has not yet
formed an opinion. In the meantime, there is POSIX.
--
Lawrence Crowl
More information about the Gcc-help
mailing list