зеркало из https://github.com/github/ruby.git
* gc.c (gc_mark_children): use gc_mark_ptr instead of marking
a object directly. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@36618 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
Родитель
cd060b4588
Коммит
d7a3331682
|
@ -1,3 +1,8 @@
|
|||
Sat Aug 4 20:37:56 2012 Narihiro Nakamura <authornari@gmail.com>
|
||||
|
||||
* 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@ruby-lang.org>
|
||||
|
||||
* test/ruby/test_alias.rb (test_super_in_aliased_module_method):
|
||||
|
|
6
gc.c
6
gc.c
|
@ -1839,7 +1839,6 @@ static void
|
|||
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 @@ gc_mark_children(rb_objspace_t *objspace, VALUE ptr, int lev)
|
|||
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)) {
|
||||
|
|
Загрузка…
Ссылка в новой задаче