[PATCH] libstdc++: Add mem_order_hle_acquire/release to atomic.h

Jonathan Wakely jwakely.gcc@gmail.com
Fri Nov 9 17:49:00 GMT 2012


On 9 November 2012 15:06, Andi Kleen wrote:
>
> The underlying compiler supports additional __ATOMIC_HLE_ACQUIRE/RELEASE
> memmodel flags for TSX, but this was not exposed to the C++ wrapper.
> Handle it there.

Where do these enumerator names come from?  They're certainly not part
of the C++ standard so your patch breaks this valid C++ program:

#define memory_order_hle_acquire 1
#include <atomic>

int main()
{
}

Can the enumerators be uglified to __memory_order_hle_acquire or
something like that?



More information about the Libstdc++ mailing list