X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=ghc%2Frts%2Fwin32%2FAwaitEvent.c;h=6986bc9a3627ed44b25b8e7b62b7d6e363195a0c;hb=03a9ff01812afc81eb5236fd3063cbec44cf469e;hp=edf65df94ccdbbc9ce253b56559088203ef30140;hpb=63e8af080a7e779a48e812e6caa9ea519b046260;p=ghc-hetmet.git diff --git a/ghc/rts/win32/AwaitEvent.c b/ghc/rts/win32/AwaitEvent.c index edf65df..6986bc9 100644 --- a/ghc/rts/win32/AwaitEvent.c +++ b/ghc/rts/win32/AwaitEvent.c @@ -16,7 +16,7 @@ #include "Schedule.h" #include #include "win32/AsyncIO.h" -#if defined(RTS_SUPPORTS_THREADS) +#if defined(THREADED_RTS) #include "Capability.h" #endif @@ -29,7 +29,7 @@ awaitEvent(rtsBool wait) { int ret; -#ifdef RTS_SUPPORTS_THREADS +#ifdef THREADED_RTS // Small optimisation: we don't want the waiting thread to wake // up straight away just because a previous returning worker has // called abandonRequestWait(). If the event is no longer needed, @@ -55,18 +55,18 @@ awaitEvent(rtsBool wait) // // - we were interrupted // - new threads have arrived - // - another worker wants to take over (RTS_SUPPORTS_THREADS) + // - another worker wants to take over (THREADED_RTS) } while (wait && !interrupted && run_queue_hd == END_TSO_QUEUE -#ifdef RTS_SUPPORTS_THREADS +#ifdef THREADED_RTS && !needToYieldToReturningWorker() #endif ); } -#ifdef RTS_SUPPORTS_THREADS +#ifdef THREADED_RTS void wakeBlockedWorkerThread() {