diff options
author | Rickard Green <[email protected]> | 2014-11-25 19:45:19 +0100 |
---|---|---|
committer | Rickard Green <[email protected]> | 2014-11-25 19:45:19 +0100 |
commit | 89858cf060df65d966892ee50983274d6297cea8 (patch) | |
tree | 33004ea5b8ca41f70c8965ea8c3baae650edb9f9 /erts/emulator | |
parent | 7c14d7b35f3fe6df4ab44a30ba1e3c6dac00a70b (diff) | |
parent | f4dce072bab24674295a90d06786349a252a0891 (diff) | |
download | otp-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.c | 8 |
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; } |