blob: fe16fe0eaec195e4953525553922d9fb4dd7d3e5 [file] [log] [blame]
#include <intrin.h>
unsigned char _interlockedbittestandset64(__int64 *Base, __int64 Offset)
{
int old = 0;
__asm__ __volatile__("lock ; btsq %2,%1\n\tsbbl %0,%0 "
:"=r" (old),"=m" ((*(volatile long long *) Base))
:"Ir" (Offset) : "memory");
return (old != 0);
}