[PATCH] D18201: Switch over targets to use AtomicExpandPass, and clean up target atomics code.

Tim Northover via llvm-commits llvm-commits at lists.llvm.org
Wed Mar 16 20:56:14 PDT 2016

t.p.northover added a comment.

> I don't think Darwin actually supports any pre-cx16 CPUs though, so this really shouldn't affect it. But perhaps somewhere a default CPU architecture needs to be set, if it's not already?

No, that should be fine. Thanks for the reassurances (and reminding me that AtomicExpand did it). I was initially confused by the "unnatural operations".

> That is, the lock cmpxchg16b instruction didn't fail if it returns false. It always does both a load and a store. It's just that if the comparison was false, it stores back the just-loaded value, instead of the new value.

Ah yes, see what you mean there. I agree.

Thanks again for the explanations.



More information about the llvm-commits mailing list