summaryrefslogtreecommitdiff
path: root/node.h
diff options
context:
space:
mode:
authornari <nari@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2009-05-13 14:08:26 +0000
committernari <nari@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2009-05-13 14:08:26 +0000
commit57b83a5191be20c49d5d4cff77582170a507cf88 (patch)
tree24bcde781130fad832673a8fbddf2e92c2324073 /node.h
parente7ba39350a1ed1ab2789afe4f2401a7f54ff8bb4 (diff)
* gc.c: add longlife garbage collection. [ruby-dev:38423]
(NORMAL_HEAPS_USED): new macro. (LONGLIFE_ALLOCATE_HEAPS_MIN): ditto. (add_longlife_heaps_slot): new function. (rb_newobj_from_longlife_heap): ditto. (rb_newobj_longlife): ditto. (rb_node_newnode_longlife): ditto. (rb_gc_write_barrier): ditto. (remembered_set_recycle): ditto. (rb_gc_mark_remembered_set): ditto. (clear_mark_longlife_heaps): ditto. (gc_sweep_for_longlife): ditto. (assign_heap_slot): new argumnent to longlife heaps slot. (add_freelist): ditto. (gc_sweep): avoid lonlife heap slot. set longlife_collection flag at add heap. (rb_gc_force_recycle): avoid mark object and remembered_set object. (garbage_collect): add longlife collection. (rb_gc_start): invoke longlife collection. (gc_profile_record_get): for longlife collction profile. (gc_profile_result): ditto. * include/ruby/intern.h (rb_gc_write_barrier): declared. * include/ruby/ruby.h (FL_REMEMBERED_SET): renamed from FL_RESERVED. * debug.c (FL_REMEMBERED_SET): ditto. * insns.def (setinlinecache): insert write barrier. * vm_insnhelper.c (vm_method_search): ditto. * set_relation (set_relation): use longlife object. * vm.c (vm_define_method): ditto. * vm_core.h (NEW_INLINE_CACHE_ENTRY): ditto. * vm_method.c (rb_add_method): ditto. * class.c (rb_add_method): ditto. * node.h (NEW_NODE_LONGLIFE): new macro. (rb_node_newnode_longlife): declared. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@23421 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'node.h')
-rw-r--r--node.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/node.h b/node.h
index 8de2082..c6a0fbb 100644
--- a/node.h
+++ b/node.h
@@ -354,6 +354,7 @@ typedef struct RNode {
#define nd_visi u2.argc
#define NEW_NODE(t,a0,a1,a2) rb_node_newnode((t),(VALUE)(a0),(VALUE)(a1),(VALUE)(a2))
+#define NEW_NODE_LONGLIFE(t,a0,a1,a2) rb_node_newnode_longlife((t),(VALUE)(a0),(VALUE)(a1),(VALUE)(a2))
#define NEW_METHOD(n,x,v) NEW_NODE(NODE_METHOD,x,n,v)
#define NEW_FBODY(n,i) NEW_NODE(NODE_FBODY,i,n,0)
@@ -497,6 +498,7 @@ NODE *rb_compile_file(const char*, VALUE, int);
void rb_add_method(VALUE, ID, NODE *, int);
NODE *rb_node_newnode(enum node_type,VALUE,VALUE,VALUE);
+NODE *rb_node_newnode_longlife(enum node_type,VALUE,VALUE,VALUE);
NODE* rb_method_node(VALUE klass, ID id);
int rb_node_arity(NODE* node);