summaryrefslogtreecommitdiff
path: root/rts/Schedule.c
diff options
context:
space:
mode:
authorSimon Marlow <marlowsd@gmail.com>2009-02-09 11:25:36 +0000
committerSimon Marlow <marlowsd@gmail.com>2009-02-09 11:25:36 +0000
commita233641531c30f3ae5839a02d60e342fd2c87e58 (patch)
treeac355a06f46630a6168991ddbc0de3538c32ae80 /rts/Schedule.c
parent305b24aa09287ce3d3b5e9817a5be745e0f17232 (diff)
downloadhaskell-a233641531c30f3ae5839a02d60e342fd2c87e58.tar.gz
scheduleYield(): check the wakeup queue before yielding
Diffstat (limited to 'rts/Schedule.c')
-rw-r--r--rts/Schedule.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/rts/Schedule.c b/rts/Schedule.c
index 978adb89c8..6c46c093bc 100644
--- a/rts/Schedule.c
+++ b/rts/Schedule.c
@@ -744,6 +744,7 @@ scheduleYield (Capability **pcap, Task *task)
// if we have work, and we don't need to give up the Capability, continue.
if (!shouldYieldCapability(cap,task) &&
(!emptyRunQueue(cap) ||
+ !emptyWakeupQueue(cap) ||
blackholes_need_checking ||
sched_state >= SCHED_INTERRUPTING))
return;