ruby-changes:24567
From: nari <ko1@a...>
Date: Sat, 4 Aug 2012 20:41:10 +0900 (JST)
Subject: [ruby-changes:24567] nari:r36618 (trunk): * gc.c (gc_mark_children): use gc_mark_ptr instead of marking
nari 2012-08-04 20:40:59 +0900 (Sat, 04 Aug 2012) New Revision: 36618 http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=36618 Log: * gc.c (gc_mark_children): use gc_mark_ptr instead of marking a object directly. Modified files: trunk/ChangeLog trunk/gc.c Index: ChangeLog =================================================================== --- ChangeLog (revision 36617) +++ ChangeLog (revision 36618) @@ -1,3 +1,8 @@ +Sat Aug 4 20:37:56 2012 Narihiro Nakamura <authornari@g...> + + * gc.c (gc_mark_children): use gc_mark_ptr instead of marking + a object directly. + Sat Aug 4 10:02:03 2012 Shugo Maeda <shugo@r...> * test/ruby/test_alias.rb (test_super_in_aliased_module_method): Index: gc.c =================================================================== --- gc.c (revision 36617) +++ gc.c (revision 36618) @@ -1839,7 +1839,6 @@ gc_mark_children(rb_objspace_t *objspace, VALUE ptr, int lev) { register RVALUE *obj = RANY(ptr); - register uintptr_t *bits; goto marking; /* skip */ @@ -1847,10 +1846,7 @@ obj = RANY(ptr); if (rb_special_const_p(ptr)) return; /* special const not marked */ if (obj->as.basic.flags == 0) return; /* free cell */ - bits = GET_HEAP_BITMAP(ptr); - if (MARKED_IN_BITMAP(bits, ptr)) return; /* already marked */ - MARK_IN_BITMAP(bits, ptr); - objspace->heap.live_num++; + if (!gc_mark_ptr(objspace, ptr)) return; /* already marked */ marking: if (FL_TEST(obj, FL_EXIVAR)) { -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/