Ruby 2.7.0p0(2019-12-25revision647ee6f091eafcce70ffb75ddf7e121e192ab217)

Macros | Functions
thread.h File Reference
`#include "ruby/intern.h"`

Go to the source code of this file.

## Macros
#define | RB_NOGVL_INTR_FAIL (0x1)
#define | RB_NOGVL_UBF_ASYNC_SAFE (0x2)
#define | RUBY_CALL_WO_GVL_FLAG_SKIP_CHECK_INTS_AFTER 0x01
#define | RUBY_CALL_WO_GVL_FLAG_SKIP_CHECK_INTS_

## Functions
RUBY_SYMBOL_EXPORT_BEGIN void * | rb_thread_call_with_gvl (void *(*func)(void *), void *data1)
void * | rb_thread_call_without_gvl (void *(*func)(void *), void *data1, rb_unblock_function_t *ubf, void *data2)
void * | rb_thread_call_without_gvl2 (void *(*func)(void *), void *data1, rb_unblock_function_t *ubf, void *data2)
void * | rb_nogvl (void *(*func)(void *), void *data1, rb_unblock_function_t *ubf, void *data2, int flags)

## Macro Definition Documentation

## ◆ RB_NOGVL_INTR_FAIL

#define RB_NOGVL_INTR_FAIL (0x1)

Definition at line 25 of file thread.h.

## ◆ RB_NOGVL_UBF_ASYNC_SAFE

#define RB_NOGVL_UBF_ASYNC_SAFE (0x2)

Definition at line 26 of file thread.h.

## ◆ RUBY_CALL_WO_GVL_FLAG_SKIP_CHECK_INTS_

#define RUBY_CALL_WO_GVL_FLAG_SKIP_CHECK_INTS_

Definition at line 46 of file thread.h.

## ◆ RUBY_CALL_WO_GVL_FLAG_SKIP_CHECK_INTS_AFTER

#define RUBY_CALL_WO_GVL_FLAG_SKIP_CHECK_INTS_AFTER 0x01

Definition at line 45 of file thread.h.

## Function Documentation

## ◆ rb_nogvl()

void* rb_nogvl | ( | void *(*)(void *) | func,
|  | void * | data1,
|  | rb_unblock_function_t * | ubf,
|  | void * | data2,
|  | int | flags
| ) |  |

Definition at line 1452 of file thread.c.

References GET_EC.

Referenced by rb_thread_call_without_gvl(), and rb_thread_call_without_gvl2().

## ◆ rb_thread_call_with_gvl()

RUBY_SYMBOL_EXPORT_BEGIN void* rb_thread_call_with_gvl | ( | void *(*)(void *) | func,
|  | void * | data1
| ) |  |

Definition at line 1662 of file thread.c.

References rb_thread_struct::blocking_region_buffer, exit(), EXIT_FAILURE, fprintf(), if(), rb_bug(), stderr, waiting_fd::th, and rb_thread_struct::unblock.

Referenced by ossl_generate_cb_2().

## ◆ rb_thread_call_without_gvl()

void* rb_thread_call_without_gvl | ( | void *(*)(void *) | func,
|  | void * | data1,
|  | rb_unblock_function_t * | ubf,
|  | void * | data2
| ) |  |

Referenced by rb_getnameinfo().

## ◆ rb_thread_call_without_gvl2()

void* rb_thread_call_without_gvl2 | ( | void *(*)(void *) | func,
|  | void * | data1,
|  | rb_unblock_function_t * | ubf,
|  | void * | data2
| ) |  |

Definition at line 1581 of file thread.c.

References rb_nogvl(), and RB_NOGVL_INTR_FAIL.