File: blocking_io_region.h

package info (click to toggle)
ruby-kgio 2.11.2-2
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, bullseye, forky, sid, trixie
  • size: 504 kB
  • sloc: ruby: 2,779; ansic: 2,017; sh: 32; makefile: 5
file content (12 lines) | stat: -rw-r--r-- 539 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
#ifdef KGIO_WITHOUT_GVL
#  if   defined(HAVE_RB_THREAD_IO_BLOCKING_REGION)
/* temporary API for Ruby 1.9.3 */
VALUE rb_thread_io_blocking_region(rb_blocking_function_t *, void *, int);
#  elif defined(HAVE_RB_THREAD_CALL_WITHOUT_GVL)
#    define rb_thread_io_blocking_region(fn,data,fd) \
            rb_thread_call_without_gvl((fn),(data),RUBY_UBF_IO,0)
#  elif defined(HAVE_RB_THREAD_BLOCKING_REGION)
#    define rb_thread_io_blocking_region(fn,data,fd) \
            rb_thread_blocking_region((fn),(data),RUBY_UBF_IO,0)
#  endif
#endif