OSDN Git Service

swr: [rasterizer common] add linux definition for InterlockedAdd64
authorTim Rowley <timothy.o.rowley@intel.com>
Tue, 9 Aug 2016 06:44:39 +0000 (00:44 -0600)
committerTim Rowley <timothy.o.rowley@intel.com>
Wed, 10 Aug 2016 16:09:22 +0000 (11:09 -0500)
Signed-off-by: Tim Rowley <timothy.o.rowley@intel.com>
src/gallium/drivers/swr/rasterizer/common/os.h

index 32eca68..43d5513 100644 (file)
@@ -220,6 +220,8 @@ void AlignedFree(void* p)
 #define InterlockedDecrement(Append) __sync_sub_and_fetch(Append, 1)
 #define InterlockedDecrement64(Append) __sync_sub_and_fetch(Append, 1)
 #define InterlockedIncrement(Append) __sync_add_and_fetch(Append, 1)
+#define InterlockedAdd(Addend, Value) __sync_add_and_fetch(Addend, Value)
+#define InterlockedAdd64(Addend, Value) __sync_add_and_fetch(Addend, Value)
 #define _ReadWriteBarrier() asm volatile("" ::: "memory")
 
 #define PRAGMA_WARNING_PUSH_DISABLE(...)