diff options
author | John Hawthorn <[email protected]> | 2023-12-08 21:16:02 -0800 |
---|---|---|
committer | John Hawthorn <[email protected]> | 2023-12-09 09:31:41 -0800 |
commit | b2ad4fec1a369e1cbd0c65d52062946a4fbfb84b (patch) | |
tree | 2762a08d89a4a06182a73337ddbc076561fe3d21 /thread_pthread.c | |
parent | 88d9a4d58af5c41a3258761dd6d0ea405fe47c07 (diff) |
Add missing GVL hooks for M:N threads and ractors
Diffstat (limited to 'thread_pthread.c')
-rw-r--r-- | thread_pthread.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/thread_pthread.c b/thread_pthread.c index a8cf8c6126..64b636ec08 100644 --- a/thread_pthread.c +++ b/thread_pthread.c @@ -1304,6 +1304,8 @@ rb_ractor_sched_sleep(rb_execution_context_t *ec, rb_ractor_t *cr, rb_unblock_fu RB_VM_SAVE_MACHINE_CONTEXT(th); th->status = THREAD_STOPPED_FOREVER; + RB_INTERNAL_THREAD_HOOK(RUBY_INTERNAL_THREAD_EVENT_SUSPENDED, th); + bool can_direct_transfer = !th_has_dedicated_nt(th); thread_sched_wakeup_next_thread(sched, th, can_direct_transfer); thread_sched_wait_running_turn(sched, th, can_direct_transfer); |