https://gcc.gnu.org/bugzilla/show_bug.cgi?id=101761

--- Comment #9 from Jonathan Wakely <redi at gcc dot gnu.org> ---
My point is that *any* read of aa is undefined while there is an atomic_ref
using it, even in the absence of other threads.

It happens to cause the race you describe, because the value of aa is changing
concurrently. But it's undefined according to the standard even without that.

Reply via email to