*
* (c) The GHC Team, 2005
*
- * Macros for SMP support
+ * Macros for THREADED_RTS support
*
* -------------------------------------------------------------------------- */
#ifndef SMP_H
#define SMP_H
-/* SMP is currently not compatible with the following options:
+/* THREADED_RTS is currently not compatible with the following options:
*
- * INTERPRETER
- * PROFILING
+ * PROFILING (but only 1 CPU supported)
* TICKY_TICKY
- * and unregisterised builds.
+ * Unregisterised builds are ok, but only 1 CPU supported.
*/
-#if defined(SMP)
+#if defined(THREADED_RTS)
-#if defined(PROFILING) || defined(TICKY_TICKY)
-#error Build options incompatible with SMP.
+#if defined(TICKY_TICKY)
+#error Build options incompatible with THREADED_RTS.
#endif
/*
#endif
}
-#endif /* SMP */
+#else /* !THREADED_RTS */
+
+#define wb() /* nothing */
+
+INLINE_HEADER StgWord
+xchg(StgPtr p, StgWord w)
+{
+ StgWord old = *p;
+ *p = w;
+ return old;
+}
+
+#endif /* !THREADED_RTS */
#endif /* SMP_H */