cmpxchg synchronizes with other atomic operations. Both ordering parameters must be at least monotonic , the ordering constraint on failure must be no stronger than that on success, and the failure ordering cannot be either release or acq_rel ."The LLVM source interprets it as https://github.com/llvm/llvm-project/blob/a5d375e0cbc4abf6e318270a1bc9c1c0961ae565/llvm/include/llvm/Support/AtomicOrdering.h#L89 .
We should probably drop the requirement; the C++ standard dropped the corresponding requirement for the library call. See http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2016/p0418r2.html .
-Eli