Align libgc vcxproj with makefile.
[mono.git] / mono / utils / unlocked.h
index 6c4abcf468286674a1738b8276e37e9b9bd3e0ba..8a1e98bb2ee7068e6246e130b186c16abcca09d3 100644 (file)
@@ -20,6 +20,8 @@
 
 #if MONO_HAS_CLANG_THREAD_SANITIZER
 #define MONO_UNLOCKED_ATTRS MONO_NO_SANITIZE_THREAD MONO_NEVER_INLINE static
+#elif defined(_MSC_VER)
+#define MONO_UNLOCKED_ATTRS MONO_ALWAYS_INLINE static
 #else
 #define MONO_UNLOCKED_ATTRS MONO_ALWAYS_INLINE static inline
 #endif
@@ -66,6 +68,13 @@ UnlockedAdd64 (gint64 *dest, gint64 add)
        return *dest += add;
 }
 
+MONO_UNLOCKED_ATTRS
+gdouble
+UnlockedAddDouble (gdouble *dest, gdouble add)
+{
+       return *dest += add;
+}
+
 MONO_UNLOCKED_ATTRS
 gint64
 UnlockedSubtract64 (gint64 *dest, gint64 sub)
@@ -87,6 +96,13 @@ UnlockedWrite64 (gint64 *dest, gint64 val)
        *dest = val;
 }
 
+MONO_UNLOCKED_ATTRS
+void
+UnlockedWriteBool (gboolean *dest, gboolean val)
+{
+       *dest = val;
+}
+
 MONO_UNLOCKED_ATTRS
 gint32
 UnlockedRead (gint32 *src)
@@ -101,4 +117,18 @@ UnlockedRead64 (gint64 *src)
        return *src;
 }
 
+MONO_UNLOCKED_ATTRS
+gboolean
+UnlockedReadBool (gboolean *src)
+{
+       return *src;
+}
+
+MONO_UNLOCKED_ATTRS
+gpointer
+UnlockedReadPointer (volatile gpointer *src)
+{
+       return *src;
+}
+
 #endif /* _UNLOCKED_H_ */