https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103066
H.J. Lu <hjl.tools at gmail dot com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|UNCONFIRMED |NEW Ever confirmed|0 |1 Last reconfirmed| |2021-11-05 --- Comment #2 from H.J. Lu <hjl.tools at gmail dot com> --- (In reply to Hongyu Wang from comment #1) > __sync_val_compare_and_swap will be expanded to > atomic_compare_exchange_strong > by default, should we restrict the check and return under > atomic_compare_exchange_weak which is allowed to fail spuriously? On x86, "lock cmpxchgl" can fail.