summaryrefslogtreecommitdiff
path: root/rts/Task.h
diff options
context:
space:
mode:
authorSimon Marlow <marlowsd@gmail.com>2010-09-15 12:06:27 +0000
committerSimon Marlow <marlowsd@gmail.com>2010-09-15 12:06:27 +0000
commit65da401ae6579ad47f06bcf80b1f3022c9963ca4 (patch)
tree71782907aa7a9043b00f0f8e52498817469225e9 /rts/Task.h
parentc76348fc03f302ffd8201b912eef4724b3fa60a4 (diff)
downloadhaskell-65da401ae6579ad47f06bcf80b1f3022c9963ca4.tar.gz
Windows: use a thread-local variable for myTask()
Which entailed fixing an incorrect #ifdef in Task.c
Diffstat (limited to 'rts/Task.h')
-rw-r--r--rts/Task.h5
1 files changed, 3 insertions, 2 deletions
diff --git a/rts/Task.h b/rts/Task.h
index f91872f9a0..566c0425cd 100644
--- a/rts/Task.h
+++ b/rts/Task.h
@@ -233,8 +233,9 @@ void startWorkerTask (Capability *cap);
// A thread-local-storage key that we can use to get access to the
// current thread's Task structure.
#if defined(THREADED_RTS)
-#if defined(linux_HOST_OS) && \
- (defined(i386_HOST_ARCH) || defined(x86_64_HOST_ARCH))
+#if (defined(linux_HOST_OS) && \
+ (defined(i386_HOST_ARCH) || defined(x86_64_HOST_ARCH))) || \
+ (defined(mingw32_HOST_OS) && __GNUC__ >= 4 && __GNUC_MINOR__ >= 4)
#define MYTASK_USE_TLV
extern __thread Task *my_task;
#else