diff options
author | Koichi Sasada <ko1@atdot.net> | 2023-03-30 02:41:45 +0900 |
---|---|---|
committer | Koichi Sasada <ko1@atdot.net> | 2023-03-30 14:56:37 +0900 |
commit | f5b824c745782d02b9420f8626f633e3de748d73 (patch) | |
tree | 3aab4671c2a92b8029e4e086d2fa1c1f4f6eb57c /ractor.c | |
parent | 30b43f4f1a37641edc0b146b8a648686a65a3aef (diff) |
show debug log for `ractor_terminal_interrupt_all`
Notes
Notes:
Merged: https://github.com/ruby/ruby/pull/7616
Diffstat (limited to 'ractor.c')
-rw-r--r-- | ractor.c | 5 |
1 files changed, 4 insertions, 1 deletions
@@ -2322,6 +2322,7 @@ ractor_terminal_interrupt_all(rb_vm_t *vm) rb_ractor_t *r = 0; ccan_list_for_each(&vm->ractor.set, r, vmlr_node) { if (r != vm->ractor.main_ractor) { + RUBY_DEBUG_LOG("r:%d", rb_ractor_id(r)); rb_ractor_terminate_interrupt_main_thread(r); } } @@ -2338,7 +2339,9 @@ rb_ractor_terminate_all(void) if (vm->ractor.cnt > 1) { RB_VM_LOCK(); - ractor_terminal_interrupt_all(vm); // kill all ractors + { + ractor_terminal_interrupt_all(vm); // kill all ractors + } RB_VM_UNLOCK(); } rb_thread_terminate_all(GET_THREAD()); // kill other threads in main-ractor and wait |