impatomic: add atomic_{thread,signal}_fence() definitions
[c11tester.git] / include / impatomic.h
index 7ecc373..b64df7a 100644 (file)
@@ -3846,4 +3846,17 @@ T* atomic<T*>::fetch_sub( ptrdiff_t __v__, memory_order __x__ ) volatile
 } // namespace std
 #endif
 
 } // namespace std
 #endif
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+inline void atomic_thread_fence(memory_order order)
+{ _ATOMIC_FENCE_(order); }
+
+/** @todo Do we want to try to support a user's signal-handler? */
+inline void atomic_signal_fence(memory_order order)
+{ /* No-op? */ }
+#ifdef __cplusplus
+}
+#endif
+
 #endif /* __IMPATOMIC_H__ */
 #endif /* __IMPATOMIC_H__ */