From: simonmar Date: Fri, 25 Nov 2005 13:06:25 +0000 (+0000) Subject: [project @ 2005-11-25 13:06:25 by simonmar] X-Git-Tag: Initial_conversion_from_CVS_complete~11 X-Git-Url: http://git.megacz.com/?a=commitdiff_plain;h=66cfe3cedfb885796a3f4cd2609017808d200ea1;hp=062c0fabde0fd011b0a6c37c8e02d01faa9a8d31;p=ghc-hetmet.git [project @ 2005-11-25 13:06:25 by simonmar] define wb() and xchg() for non-SMP versions of the RTS --- diff --git a/ghc/includes/SMP.h b/ghc/includes/SMP.h index d8f2aa1..88fc339 100644 --- a/ghc/includes/SMP.h +++ b/ghc/includes/SMP.h @@ -113,6 +113,18 @@ unlockClosure(StgClosure *p, StgInfoTable *info) #endif } -#endif /* SMP */ +#else /* !SMP */ + +#define wb() /* nothing */ + +INLINE_HEADER StgWord +xchg(StgPtr p, StgWord w) +{ + StgWord old = *p; + *p = w; + return old; +} + +#endif /* !SMP */ #endif /* SMP_H */