https://bugs.ruby-lang.org/https://bugs.ruby-lang.org/favicon.ico?17113305112021-08-18T20:46:57ZRuby Issue Tracking SystemRuby master - Bug #18117: Segmentation fault when yielding values from Ractors during GC sweepinghttps://bugs.ruby-lang.org/issues/18117?journal_id=933752021-08-18T20:46:57Zvinistock (Vinicius Stock)
<ul><li><strong>Description</strong> updated (<a title="View differences" href="/journals/93375/diff?detail_id=60637">diff</a>)</li></ul> Ruby master - Bug #18117: Segmentation fault when yielding values from Ractors during GC sweepinghttps://bugs.ruby-lang.org/issues/18117?journal_id=933762021-08-18T20:47:44Zpeterzhu2118 (Peter Zhu)peter@peterzhu.ca
<ul><li><strong>Assignee</strong> set to <i>peterzhu2118 (Peter Zhu)</i></li><li><strong>Backport</strong> changed from <i>2.6: UNKNOWN, 2.7: UNKNOWN, 3.0: UNKNOWN</i> to <i>2.6: DONTNEED, 2.7: DONTNEED, 3.0: REQUIRED</i></li></ul> Ruby master - Bug #18117: Segmentation fault when yielding values from Ractors during GC sweepinghttps://bugs.ruby-lang.org/issues/18117?journal_id=934722021-08-24T13:48:24Zpeterzhu2118 (Peter Zhu)peter@peterzhu.ca
<ul><li><strong>Status</strong> changed from <i>Open</i> to <i>Closed</i></li></ul><p>Applied in changeset <a class="changeset" title="[Bug #18117] Fix Ractor race condition with GC rb_objspace_reachable_objects_from requires that ..." href="https://bugs.ruby-lang.org/projects/ruby-master/repository/git/revisions/bbedd29b6e98ef6e3fc2ce2b358d2b509b7cd1bb">git|bbedd29b6e98ef6e3fc2ce2b358d2b509b7cd1bb</a>.</p>
<hr>
<p>[Bug <a class="issue tracker-1 status-5 priority-4 priority-default closed" title="Bug: Segmentation fault when yielding values from Ractors during GC sweeping (Closed)" href="https://bugs.ruby-lang.org/issues/18117">#18117</a>] Fix Ractor race condition with GC</p>
<p>rb_objspace_reachable_objects_from requires that the GC not be active.<br>
Since the Ractor barrier is not executed for incremental sweeping,<br>
Ractor may call rb_objspace_reachable_objects_from after sweeping<br>
has started to share objects. This causes a crash that looks like<br>
the following:</p>
<pre><code><internal:ractor>:627: [BUG] rb_objspace_reachable_objects_from() is not supported while during_gc == true
</code></pre>
<p>Co-authored-by: Vinicius Stock <a href="mailto:vinicius.stock@shopify.com" class="email">vinicius.stock@shopify.com</a></p> Ruby master - Bug #18117: Segmentation fault when yielding values from Ractors during GC sweepinghttps://bugs.ruby-lang.org/issues/18117?journal_id=935582021-09-05T05:12:47Znagachika (Tomoyuki Chikanaga)nagachika00@gmail.com
<ul><li><strong>Backport</strong> changed from <i>2.6: DONTNEED, 2.7: DONTNEED, 3.0: REQUIRED</i> to <i>2.6: DONTNEED, 2.7: DONTNEED, 3.0: DONE</i></li></ul><p>ruby_3_0 3fb51aec5ba7decffdfc32e540262aaae6167a95 merged revision(s) bbedd29b6e98ef6e3fc2ce2b358d2b509b7cd1bb.</p>