From 6f09fc2efd1915c4337ce6dded52a8a8771c3222 Mon Sep 17 00:00:00 2001 From: ko1 Date: Mon, 12 Jan 2009 01:43:23 +0000 Subject: * thread.c: fix comment (terminology: Global VM Lock). * thread.c (blocking_region_begin, blocking_region_end): save and clear th->blocking_region_buffer. * thread.c (rb_thread_call_with_gvl): check if it has GVL. * thread.c (ruby_thread_has_gvl_p): added. * vm_core.h: add decls. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@21438 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- vm_core.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'vm_core.h') diff --git a/vm_core.h b/vm_core.h index fea803986f..7ccd0de16d 100644 --- a/vm_core.h +++ b/vm_core.h @@ -588,6 +588,9 @@ VALUE vm_invoke_proc(rb_thread_t *th, rb_proc_t *proc, VALUE self, VALUE vm_make_proc(rb_thread_t *th, const rb_block_t *block, VALUE klass); VALUE vm_make_env_object(rb_thread_t *th, rb_control_frame_t *cfp); +void *rb_thread_call_with_gvl(void *(*func)(void *), void *data1); +int ruby_thread_has_gvl_p(void); + NOINLINE(void rb_gc_save_machine_context(rb_thread_t *)); #define sysstack_error GET_VM()->special_exceptions[ruby_error_sysstack] -- cgit v1.2.3