Ruby
2.1.10p492(2016-04-01revision54464)
|
Go to the source code of this file.
Macros | |
#define | SET_MACHINE_STACK_END(p) rb_gc_set_stack_end(p) |
#define | USE_CONSERVATIVE_STACK_END |
#define | RUBY_MARK_FREE_DEBUG 0 |
#define | RUBY_MARK_ENTER(msg) |
#define | RUBY_MARK_LEAVE(msg) |
#define | RUBY_FREE_ENTER(msg) |
#define | RUBY_FREE_LEAVE(msg) |
#define | RUBY_GC_INFO if(0)printf |
#define | RUBY_MARK_UNLESS_NULL(ptr) if(RTEST(ptr)){rb_gc_mark(ptr);} |
#define | RUBY_FREE_UNLESS_NULL(ptr) if(ptr){ruby_xfree(ptr);(ptr)=NULL;} |
#define | stack_growup_p(x) |
#define | STACK_UPPER(x, a, b) (stack_growup_p(x) ? (a) : (b)) |
#define | STACK_GROW_DIR_DETECTION VALUE stack_grow_dir_detection |
#define | STACK_DIR_UPPER(a, b) STACK_UPPER(&stack_grow_dir_detection, (a), (b)) |
#define | IS_STACK_DIR_UPPER() STACK_DIR_UPPER(1,0) |
Functions | |
NOINLINE (void rb_gc_set_stack_end(VALUE **stack_end_p)) | |
int | ruby_get_stack_grow_direction (volatile VALUE *addr) |
RUBY_SYMBOL_EXPORT_BEGIN size_t | rb_objspace_data_type_memsize (VALUE obj) |
void | rb_objspace_reachable_objects_from (VALUE obj, void(func)(VALUE, void *), void *data) |
void | rb_objspace_reachable_objects_from_root (void(func)(const char *category, VALUE, void *), void *data) |
int | rb_objspace_markable_object_p (VALUE obj) |
int | rb_objspace_internal_object_p (VALUE obj) |
void | rb_objspace_each_objects (int(*callback)(void *start, void *end, size_t stride, void *data), void *data) |
Variables | |
RUBY_EXTERN int | ruby_stack_grow_direction |
#define IS_STACK_DIR_UPPER | ( | ) | STACK_DIR_UPPER(1,0) |
#define RUBY_FREE_ENTER | ( | msg | ) |
Definition at line 55 of file gc.h.
Referenced by binding_free(), cont_free(), env_free(), fiber_free(), iseq_free(), proc_free(), ruby_vm_destruct(), and thread_free().
#define RUBY_FREE_LEAVE | ( | msg | ) |
Definition at line 56 of file gc.h.
Referenced by binding_free(), cont_free(), env_free(), fiber_free(), iseq_free(), proc_free(), ruby_vm_destruct(), and thread_free().
#define RUBY_FREE_UNLESS_NULL | ( | ptr | ) | if(ptr){ruby_xfree(ptr);(ptr)=NULL;} |
Definition at line 61 of file gc.h.
Referenced by cont_free(), env_free(), iseq_free(), and thread_free().
#define RUBY_GC_INFO if(0)printf |
Definition at line 57 of file gc.h.
Referenced by env_mark(), iseq_free(), iseq_mark(), rb_vm_mark(), and thread_free().
#define RUBY_MARK_ENTER | ( | msg | ) |
Definition at line 53 of file gc.h.
Referenced by binding_mark(), cont_mark(), env_mark(), fiber_mark(), inst_mark(), iseq_mark(), proc_mark(), rb_thread_mark(), and rb_vm_mark().
#define RUBY_MARK_LEAVE | ( | msg | ) |
Definition at line 54 of file gc.h.
Referenced by binding_mark(), cont_mark(), env_mark(), fiber_mark(), inst_mark(), iseq_mark(), proc_mark(), rb_thread_mark(), and rb_vm_mark().
#define RUBY_MARK_UNLESS_NULL | ( | ptr | ) | if(RTEST(ptr)){rb_gc_mark(ptr);} |
Definition at line 60 of file gc.h.
Referenced by binding_mark(), env_mark(), inst_mark(), iseq_mark(), proc_mark(), rb_thread_mark(), and rb_vm_mark().
#define SET_MACHINE_STACK_END | ( | p | ) | rb_gc_set_stack_end(p) |
Definition at line 11 of file gc.h.
Referenced by cont_save_machine_stack(), Init_Cont(), and ruby_get_stack_grow_direction().
#define STACK_DIR_UPPER | ( | a, | |
b | |||
) | STACK_UPPER(&stack_grow_dir_detection, (a), (b)) |
#define stack_growup_p | ( | x | ) |
#define STACK_UPPER | ( | x, | |
a, | |||
b | |||
) | (stack_growup_p(x) ? (a) : (b)) |
Definition at line 74 of file gc.h.
Referenced by ruby_cleanup(), and ruby_stack_length().
NOINLINE | ( | void | rb_gc_set_stack_endVALUE **stack_end_p | ) |
RUBY_SYMBOL_EXPORT_BEGIN size_t rb_objspace_data_type_memsize | ( | VALUE | obj | ) |
Definition at line 1383 of file gc.c.
References RTYPEDDATA_DATA, RTYPEDDATA_P, and RTYPEDDATA_TYPE.
Referenced by obj_memsize_of().
void rb_objspace_each_objects | ( | int(*)(void *start, void *end, size_t stride, void *data) | callback, |
void * | data | ||
) |
int rb_objspace_internal_object_p | ( | VALUE | obj | ) |
Definition at line 1810 of file gc.c.
References internal_object_p().
Referenced by reachable_object_from_i(), and reachable_object_from_root_i().
int rb_objspace_markable_object_p | ( | VALUE | obj | ) |
Definition at line 2281 of file gc.c.
References is_live_object(), is_markable_object(), and rb_objspace.
Referenced by reachable_object_from_i(), reachable_object_from_root_i(), and reachable_objects_from().
Definition at line 5782 of file gc.c.
References func, gc_mark_children(), is_markable_object(), rb_objspace::mark_func_data, objspace_and_reason::objspace, and rb_objspace.
Referenced by dump_object(), reachable_objects_from(), and verify_internal_consistency_i().
void rb_objspace_reachable_objects_from_root | ( | void(func)(const char *category, VALUE, void *) | , |
void * | data | ||
) |
Definition at line 5810 of file gc.c.
References root_objects_data::category, root_objects_data::data, func, root_objects_data::func, gc_mark_roots(), rb_objspace::mark_func_data, rb_objspace, root_objects_from(), and TRUE.
Referenced by objspace_dump_all(), and reachable_objects_from_root().
int ruby_get_stack_grow_direction | ( | volatile VALUE * | addr | ) |
Definition at line 3242 of file gc.c.
References ruby_stack_grow_direction, and SET_MACHINE_STACK_END.
RUBY_EXTERN int ruby_stack_grow_direction |