ruby-changes:70745
From: Peter <ko1@a...>
Date: Wed, 5 Jan 2022 23:33:15 +0900 (JST)
Subject: [ruby-changes:70745] 6f7e02bf46 (master): Remove assertion causing read barrier to trigger
https://git.ruby-lang.org/ruby.git/commit/?id=6f7e02bf46 From 6f7e02bf46d9c7e778e710fb3761d2d9c44124f2 Mon Sep 17 00:00:00 2001 From: Peter Zhu <peter@p...> Date: Wed, 5 Jan 2022 08:51:59 -0500 Subject: Remove assertion causing read barrier to trigger GET_HEAP_PAGE reads the page. If during compaction there is a read barrier on the page, it causes the read barrier to trigger. --- gc.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/gc.c b/gc.c index b00140bee67..2c917e4faab 100644 --- a/gc.c +++ b/gc.c @@ -2851,8 +2851,6 @@ is_pointer_to_heap(rb_objspace_t *objspace, void *ptr) https://github.com/ruby/ruby/blob/trunk/gc.c#L2851 page = heap_page_for_ptr(objspace, (uintptr_t)ptr); if (page) { - GC_ASSERT(page == GET_HEAP_PAGE(ptr)); - RB_DEBUG_COUNTER_INC(gc_isptr_maybe); if (page->flags.in_tomb) { return FALSE; -- cgit v1.2.1 -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/