ruby-changes:32200
From: ko1 <ko1@a...>
Date: Thu, 19 Dec 2013 00:27:51 +0900 (JST)
Subject: [ruby-changes:32200] ko1:r44279 (trunk): * gc.c (garbage_collect_body): lazy_sweep setting should work
ko1 2013-12-19 00:27:41 +0900 (Thu, 19 Dec 2013) New Revision: 44279 http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=44279 Log: * gc.c (garbage_collect_body): lazy_sweep setting should work without USE_RGENGC. Modified files: trunk/ChangeLog trunk/gc.c Index: ChangeLog =================================================================== --- ChangeLog (revision 44278) +++ ChangeLog (revision 44279) @@ -1,3 +1,8 @@ https://github.com/ruby/ruby/blob/trunk/ChangeLog#L1 +Thu Dec 19 00:26:11 2013 Koichi Sasada <ko1@a...> + + * gc.c (garbage_collect_body): lazy_sweep setting should work + without USE_RGENGC. + Wed Dec 18 23:31:04 2013 Koichi Sasada <ko1@a...> * gc.c (gc_profile_dump_major_reason): fix this function because major_reason Index: gc.c =================================================================== --- gc.c (revision 44278) +++ gc.c (revision 44279) @@ -4966,9 +4966,11 @@ garbage_collect_body(rb_objspace_t *objs https://github.com/ruby/ruby/blob/trunk/gc.c#L4966 reason |= GPR_FLAG_MAJOR_BY_STRESS; immediate_sweep = !(flag & 0x02); } - -#if USE_RGENGC else { + if (!GC_ENABLE_LAZY_SWEEP || objspace->flags.dont_lazy_sweep) { + immediate_sweep = TRUE; + } +#if USE_RGENGC if (full_mark) { reason |= GPR_FLAG_MAJOR_BY_NOFREE; } @@ -4982,12 +4984,8 @@ garbage_collect_body(rb_objspace_t *objs https://github.com/ruby/ruby/blob/trunk/gc.c#L4984 if (objspace->rgengc.old_object_count > objspace->rgengc.old_object_limit) { reason |= GPR_FLAG_MAJOR_BY_OLDGEN; } - - if (!GC_ENABLE_LAZY_SWEEP || objspace->flags.dont_lazy_sweep) { - immediate_sweep = TRUE; - } - } #endif + } if (immediate_sweep) reason |= GPR_FLAG_IMMEDIATE_SWEEP; full_mark = (reason & GPR_FLAG_MAJOR_MASK) ? TRUE : FALSE; -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/