From 904addb860eab8d1d46cea0994b67485be1c8890 Mon Sep 17 00:00:00 2001 From: Simon Marlow Date: Wed, 5 Nov 2008 15:49:28 +0000 Subject: [PATCH] don't yield the Capability if blackholes_need_checking --- rts/Schedule.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/rts/Schedule.c b/rts/Schedule.c index 569c3d0..ca6e426 100644 --- a/rts/Schedule.c +++ b/rts/Schedule.c @@ -714,7 +714,8 @@ scheduleYield (Capability **pcap, Task *task) Capability *cap = *pcap; // if we have work, and we don't need to give up the Capability, continue. - if (!emptyRunQueue(cap) && !shouldYieldCapability(cap,task)) + if (!shouldYieldCapability(cap,task) && + (!emptyRunQueue(cap) || blackholes_need_checking)) return; // otherwise yield (sleep), and keep yielding if necessary. -- 1.7.10.4