Fix threaded runtime on 64 bit big endian. Haskell trac #8134. OBS-URL: https://build.opensuse.org/request/show/205174 OBS-URL: https://build.opensuse.org/package/show/devel:languages:haskell/ghc?expand=0&rev=144
26 lines
768 B
Diff
26 lines
768 B
Diff
From 0a2e25ea54ab549ce0966ffe0ad40c80a2849032 Mon Sep 17 00:00:00 2001
|
|
From: Gustavo Luiz Duarte <gustavold@linux.vnet.ibm.com>
|
|
Date: Mon, 28 Oct 2013 13:04:12 +0000
|
|
Subject: Fix infinite loop on 64 bits big endian platforms (Trac #8134)
|
|
|
|
---
|
|
rts/STM.c | 2 +-
|
|
1 file changed, 1 insertion(+), 1 deletion(-)
|
|
|
|
diff --git a/rts/STM.c b/rts/STM.c
|
|
index 6bcb7ba..c4dcb9f 100644
|
|
--- a/rts/STM.c
|
|
+++ b/rts/STM.c
|
|
@@ -927,7 +927,7 @@ void stmPreGCHook (Capability *cap) {
|
|
static volatile StgInt64 max_commits = 0;
|
|
|
|
#if defined(THREADED_RTS)
|
|
-static volatile StgBool token_locked = FALSE;
|
|
+static volatile StgWord token_locked = FALSE;
|
|
|
|
static void getTokenBatch(Capability *cap) {
|
|
while (cas((void *)&token_locked, FALSE, TRUE) == TRUE) { /* nothing */ }
|
|
--
|
|
1.8.3.1
|
|
|