From 425fa0aeb5ced20c03b2d5edb7a409666363ea8f Mon Sep 17 00:00:00 2001 From: Samuel Williams Date: Tue, 13 May 2025 19:02:03 +0900 Subject: Make `waiting_fd` behaviour per-IO. (#13127) - `rb_thread_fd_close` is deprecated and now a no-op. - IO operations (including close) no longer take a vm-wide lock. --- include/ruby/internal/intern/thread.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'include/ruby/internal/intern') diff --git a/include/ruby/internal/intern/thread.h b/include/ruby/internal/intern/thread.h index 716375acd7..4d87452745 100644 --- a/include/ruby/internal/intern/thread.h +++ b/include/ruby/internal/intern/thread.h @@ -61,10 +61,10 @@ int rb_thread_wait_fd(int fd); int rb_thread_fd_writable(int fd); /** - * Notifies a closing of a file descriptor to other threads. Multiple threads - * can wait for the given file descriptor at once. If such file descriptor is - * closed, threads need to start propagating their exceptions. This is the API - * to kick that process. + * This funciton is now a no-op. It was previously used to interrupt threads + * that were using the given file descriptor and wait for them to finish. + * + * @deprecated Use IO with RUBY_IO_MODE_EXTERNAL and `rb_io_close` instead. * * @param[in] fd A file descriptor. * @note This function blocks until all the threads waiting for such fd -- cgit v1.2.3