[ruby-cvs:70508] normal:r63418 (trunk): io.c: cleanup copy_stream wait-for-single-fd cases

normal at ruby-lang.org normal at ruby-lang.org
Tue May 15 08:40:56 JST 2018

normal	2018-05-15 08:40:55 +0900 (Tue, 15 May 2018)

  New Revision: 63418


    io.c: cleanup copy_stream wait-for-single-fd cases
    Avoid paying unnecessary setup and teardown cost for rb_fdset_t
    on platforms (Linux) with good poll() support.  This simplifies
    code makes future changes (perhaps for sleepy GC) easier.
    * io.c (struct copy_stream_struct): remove rb_fdset_t fds
      (nogvl_wait_for_single_fd): implement with select for non-poll case
      (maygvl_copy_stream_wait_read): remove duplicate definition
      (nogvl_copy_stream_wait_write): remove #ifdef
      (copy_stream_body): remove rb_fd_set calls
      (copy_stream_finalize): remove rb_fd_term call
      (rb_io_s_copy_stream): remove rb_fd_init

  Modified files:

More information about the ruby-cvs mailing list