diff options
author | Sverker Eriksson <[email protected]> | 2017-11-07 20:54:17 +0100 |
---|---|---|
committer | Sverker Eriksson <[email protected]> | 2017-11-07 20:54:17 +0100 |
commit | c0ad082a9ab3dcaec5a9384f9bc07f78ea45c2c4 (patch) | |
tree | 3bb7fc7394e35074d915a679bd1f165b33ecc977 /erts/emulator/test | |
parent | ef0d576a15fcf74fba6691b36b06c272a2d02ad3 (diff) | |
parent | d563fdd7f3bfa5df218e3965ca45a0348514a2a7 (diff) | |
download | otp-c0ad082a9ab3dcaec5a9384f9bc07f78ea45c2c4.tar.gz otp-c0ad082a9ab3dcaec5a9384f9bc07f78ea45c2c4.tar.bz2 otp-c0ad082a9ab3dcaec5a9384f9bc07f78ea45c2c4.zip |
Merge branch 'sverker/systask-reqid-bug/OTP-14752' into maint
* sverker/systask-reqid-bug:
erts: Fix bug in systask scheduling
Diffstat (limited to 'erts/emulator/test')
-rw-r--r-- | erts/emulator/test/process_SUITE.erl | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/erts/emulator/test/process_SUITE.erl b/erts/emulator/test/process_SUITE.erl index a9f20f9928..a8bcfac84d 100644 --- a/erts/emulator/test/process_SUITE.erl +++ b/erts/emulator/test/process_SUITE.erl @@ -2532,8 +2532,13 @@ system_task_on_suspended(Config) when is_list(Config) -> end. gc_request_when_gc_disabled(Config) when is_list(Config) -> - Master = self(), AIS = erts_debug:set_internal_state(available_internal_state, true), + gc_request_when_gc_disabled_do(ref), + gc_request_when_gc_disabled_do(immed), + erts_debug:set_internal_state(available_internal_state, AIS). + +gc_request_when_gc_disabled_do(ReqIdType) -> + Master = self(), {P, M} = spawn_opt(fun () -> true = erts_debug:set_internal_state(gc_state, false), @@ -2545,7 +2550,10 @@ gc_request_when_gc_disabled(Config) when is_list(Config) -> receive after 100 -> ok end end, [monitor, link]), receive {P, gc_state, false} -> ok end, - ReqId = make_ref(), + ReqId = case ReqIdType of + ref -> make_ref(); + immed -> immed + end, async = garbage_collect(P, [{async, ReqId}]), receive {garbage_collect, ReqId, Result} -> @@ -2554,7 +2562,6 @@ gc_request_when_gc_disabled(Config) when is_list(Config) -> ok end, receive {garbage_collect, ReqId, true} -> ok end, - erts_debug:set_internal_state(available_internal_state, AIS), receive {'DOWN', M, process, P, _Reason} -> ok end, ok. |