mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* gc.c (heap_is_swept_object): use heap_page::before_sweep flag.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@43720 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
2d00e739ef
commit
2127b9cfc7
2 changed files with 6 additions and 6 deletions
|
@ -1,3 +1,7 @@
|
|||
Tue Nov 19 18:52:10 2013 Koichi Sasada <ko1@atdot.net>
|
||||
|
||||
* gc.c (heap_is_swept_object): use heap_page::before_sweep flag.
|
||||
|
||||
Tue Nov 19 18:49:32 2013 Koichi Sasada <ko1@atdot.net>
|
||||
|
||||
* gc.c (rb_objspace_reachable_objects_from_root): do major marking.
|
||||
|
|
8
gc.c
8
gc.c
|
@ -2168,12 +2168,8 @@ is_id_value(rb_objspace_t *objspace, VALUE ptr)
|
|||
static inline int
|
||||
heap_is_swept_object(rb_objspace_t *objspace, rb_heap_t *heap, VALUE ptr)
|
||||
{
|
||||
struct heap_page *page = heap->sweep_pages;
|
||||
while (page) {
|
||||
if ((VALUE)page->start <= ptr && ptr < (VALUE)(page->start + page->limit)) return FALSE;
|
||||
page = page->next;
|
||||
}
|
||||
return TRUE;
|
||||
struct heap_page *page = GET_HEAP_PAGE(ptr);
|
||||
return page->before_sweep ? FALSE : TRUE;
|
||||
}
|
||||
|
||||
static inline int
|
||||
|
|
Loading…
Reference in a new issue