Now with working on Leopard!
[oota-llvm.git] / include / llvm / System / Atomic.h
index 2f95e0f7fbbd8e31075f1bc64663e53d17fe5cc8..c6d59531917e5347db3c6cb465067ae6fcdf8731 100644 (file)
@@ -55,10 +55,10 @@ namespace llvm {
       OSMemoryBarrier();
     }
     
-    typedef volatile UInt32 cas_flag;
+    typedef volatile int32_t cas_flag;
     inline cas_flag CompareAndSwap(cas_flag* dest, cas_flag exc, cas_flag c) {
       cas_flag old = *dest;
-      OSCompareAndSwap(c, exc, dest);
+      OSAtomicCompareAndSwap32(c, exc, dest);
       return old;
     }
 #elif defined(LLVM_ON_WIN32)