[commit: ghc] master: In the non-threaded RTS, make *_barrier functions EXTERN_INLINE, not #define. (fixes #8077) (372053c)
git at git.haskell.org
git at git.haskell.org
Thu Aug 22 01:52:29 CEST 2013
Repository : ssh://git@git.haskell.org/ghc
On branch : master
Link : http://ghc.haskell.org/trac/ghc/changeset/372053c968ef92dbb822afe38f4ce70c3a7553af/ghc
>---------------------------------------------------------------
commit 372053c968ef92dbb822afe38f4ce70c3a7553af
Author: Ryan Newton <rrnewton at gmail.com>
Date: Thu Aug 1 12:18:16 2013 -0400
In the non-threaded RTS, make *_barrier functions EXTERN_INLINE, not #define. (fixes #8077)
>---------------------------------------------------------------
372053c968ef92dbb822afe38f4ce70c3a7553af
includes/stg/SMP.h | 9 ++++++---
1 file changed, 6 insertions(+), 3 deletions(-)
diff --git a/includes/stg/SMP.h b/includes/stg/SMP.h
index bfd6bbc..99c25fe 100644
--- a/includes/stg/SMP.h
+++ b/includes/stg/SMP.h
@@ -365,9 +365,12 @@ load_load_barrier(void) {
/* ---------------------------------------------------------------------- */
#else /* !THREADED_RTS */
-#define write_barrier() /* nothing */
-#define store_load_barrier() /* nothing */
-#define load_load_barrier() /* nothing */
+EXTERN_INLINE void write_barrier(void);
+EXTERN_INLINE void store_load_barrier(void);
+EXTERN_INLINE void load_load_barrier(void);
+EXTERN_INLINE void write_barrier () {} /* nothing */
+EXTERN_INLINE void store_load_barrier() {} /* nothing */
+EXTERN_INLINE void load_load_barrier () {} /* nothing */
#if !IN_STG_CODE || IN_STGCRUN
INLINE_HEADER StgWord
More information about the ghc-commits
mailing list