https://gcc.gnu.org/bugzilla/show_bug.cgi?id=70814
--- Comment #11 from Andrew Pinski <pinskia at gcc dot gnu.org> --- (In reply to Richard Earnshaw from comment #10) > (In reply to Andrew Pinski from comment #9) > > On x86, they use ifuncs for this purpose inside libatomic. Basically the > > requirement is only one libatomic can be used at a time. > > If we can guarantee that, then yes, we could do something similar if we had > fully atomic 128-bit loads. You have to guarantee that anyways because of the way libatomic is implemented. That is the lock used by the implementations has to be the same across all uses of them.