From: "kjtsanaktsidis (KJ Tsanaktsidis) via ruby-core" Date: 2023-02-18T03:05:38+00:00 Subject: [ruby-core:112484] [Ruby master Bug#19442] Remove USE_RINCGC flag Issue #19442 has been updated by kjtsanaktsidis (KJ Tsanaktsidis). > ruby_memprofiler_pprof - This uses USE_RINCGC, as a default value to GC_ENABLE_INCREMENTAL_MARK, although I'm not sure what for. Because I copied this out of `gc.c` - https://github.com/ruby/ruby/blob/c024cc05efa2b5206c4bb45066d3c8e19af7e0d9/gc.c#L471. I think I needed a copy of the GC structures to implement `is_pointer_to_heap` in my gem, and of course the shape of those structures depends on the flags Ruby was compiled with. In any case 1) I'm working (very slowly!) on a different approach to memory profiling now, 2) I completely expect new Ruby versions to break hacks like this, and 3) AFAIK absolutely nobody, myself included, is using this gem. ---------------------------------------- Bug #19442: Remove USE_RINCGC flag https://bugs.ruby-lang.org/issues/19442#change-101927 * Author: eightbitraptor (Matthew Valentine-House) * Status: Open * Priority: Normal * Backport: 2.7: UNKNOWN, 3.0: UNKNOWN, 3.1: UNKNOWN, 3.2: UNKNOWN ---------------------------------------- [GitHub PR #7317](https://github.com/ruby/ruby/pull/7313) ~~Ruby doesn't compile when USE_RINCGC is disabled. It's also not being tested in CI. As @nobu has pointed out in comments on the PR, fixing it is simple.~~ This was fixed in [this commit](https://github.com/ruby/ruby/commit/21543ac86ce0b730c1381588d7dc9eb0e32277c7) I think we should remove `USE_RINCGC` entirely and always run with incremental GC enabled, because I don't think this flag is being actively used, and removing it will simplify the code and reduce the cognitive overhead of working with the GC. We have a precedent for this: `USE_RGENGC=0` was removed [in this commit](https://github.com/ruby/ruby/commit/62c2b8c74e47652fc5bbaf6150f4acd092dfd72b) almost 3 years ago. `USE_RINCGC=0` is in a similar state. It has been broken for almost a year (since [this commit](https://github.com/ruby/ruby/commit/dde164e968e382d50b07ad4559468885cbff33ef)), and [disabled in CI for more than 2 years](https://github.com/ruby/ruby/commit/46d3ea2c2569e2e5a9ee3e7e206f07f0f8b693f5). -- https://bugs.ruby-lang.org/ ______________________________________________ ruby-core mailing list -- ruby-core@ml.ruby-lang.org To unsubscribe send an email to ruby-core-leave@ml.ruby-lang.org ruby-core info -- https://ml.ruby-lang.org/mailman3/postorius/lists/ruby-core.ml.ruby-lang.org/