diff options
author | Peter Zhu <peter@peterzhu.ca> | 2020-12-03 14:09:18 -0500 |
---|---|---|
committer | Aaron Patterson <aaron.patterson@gmail.com> | 2020-12-03 11:58:05 -0800 |
commit | 88bb1a672c49746972f4b15410fa92e9d237c43d (patch) | |
tree | dc627e1f56227ee23f14762017c138eabf4cfb88 /gc.c | |
parent | 04b96fc322fe6547d2587f5ccbe0a835af93e48d (diff) |
Skip repeated scan of object during compaction
Notes
Notes:
Merged: https://github.com/ruby/ruby/pull/3843
Diffstat (limited to 'gc.c')
-rw-r--r-- | gc.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -4484,7 +4484,7 @@ try_move(rb_objspace_t *objspace, rb_heap_t *heap, struct heap_page *sweep_page, objspace->rcompactor.total_moved++; gc_move(objspace, (VALUE)p, dest); gc_pin(objspace, (VALUE)p); - heap->compact_cursor_index = i; + heap->compact_cursor_index = i + 1; if (from_freelist) { FL_SET((VALUE)p, FL_FROM_FREELIST); } |