This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
RE: Optimization of conditional access to globals: thread-unsafe?
I thought it was pretty clear in intent: the compiler will emit
exactly one machine load/store operation for any rvalue
reference/lvalue assignment (respectively) in the source, at the exact
sequence point in the generated code corresponding to the location of
the reference in the source.
The problem is that "one machine load/store operation" and "any rvalue"
aren't precisely-defined terms. We've had numerous discussions on this
list before about how one might want to define them.