aboutsummaryrefslogtreecommitdiffstats
path: root/erts/emulator
diff options
context:
space:
mode:
authorRickard Green <[email protected]>2014-11-25 19:45:19 +0100
committerRickard Green <[email protected]>2014-11-25 19:45:19 +0100
commit89858cf060df65d966892ee50983274d6297cea8 (patch)
tree33004ea5b8ca41f70c8965ea8c3baae650edb9f9 /erts/emulator
parent7c14d7b35f3fe6df4ab44a30ba1e3c6dac00a70b (diff)
parentf4dce072bab24674295a90d06786349a252a0891 (diff)
downloadotp-89858cf060df65d966892ee50983274d6297cea8.tar.gz
otp-89858cf060df65d966892ee50983274d6297cea8.tar.bz2
otp-89858cf060df65d966892ee50983274d6297cea8.zip
Merge branch 'maint'
* maint: Do not let non-empty run-queue prevent activation of scheduler
Diffstat (limited to 'erts/emulator')
-rw-r--r--erts/emulator/beam/erl_process.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/erts/emulator/beam/erl_process.c b/erts/emulator/beam/erl_process.c
index 7b272885a7..b0e0cf13f8 100644
--- a/erts/emulator/beam/erl_process.c
+++ b/erts/emulator/beam/erl_process.c
@@ -3244,11 +3244,11 @@ chk_wake_sched(ErtsRunQueue *crq, int ix, int activate)
return 0;
wrq = ERTS_RUNQ_IX(ix);
flags = ERTS_RUNQ_FLGS_GET(wrq);
+ if (activate && !(flags & ERTS_RUNQ_FLG_SUSPENDED)) {
+ if (try_inc_no_active_runqs(ix+1))
+ (void) ERTS_RUNQ_FLGS_UNSET(wrq, ERTS_RUNQ_FLG_INACTIVE);
+ }
if (!(flags & (ERTS_RUNQ_FLG_SUSPENDED|ERTS_RUNQ_FLG_NONEMPTY))) {
- if (activate) {
- if (try_inc_no_active_runqs(ix+1))
- (void) ERTS_RUNQ_FLGS_UNSET(wrq, ERTS_RUNQ_FLG_INACTIVE);
- }
wake_scheduler(wrq);
return 1;
}