[#86787] [Ruby trunk Feature#14723] [WIP] sleepy GC — ko1@...

Issue #14723 has been updated by ko1 (Koichi Sasada).

13 messages 2018/05/01
[#86790] Re: [Ruby trunk Feature#14723] [WIP] sleepy GC — Eric Wong <normalperson@...> 2018/05/01

ko1@atdot.net wrote:

[#87095] [Ruby trunk Feature#14767] [PATCH] gc.c: use monotonic counters for objspace_malloc_increase — ko1@...

Issue #14767 has been updated by ko1 (Koichi Sasada).

9 messages 2018/05/17

[ruby-core:87094] Re: [Ruby trunk Feature#14767] [PATCH] gc.c: use monotonic counters for objspace_malloc_increase

From: Eric Wong <normalperson@...>
Date: 2018-05-17 02:03:50 UTC
List: ruby-core #87094
ko1@atdot.net wrote:
> The only one problem is, if we have a bug (and it can be. because nobody test malloc/free counts), the values grow into strange values.

I think we may get strange values with malloc_increase
currently, too.  Not a big deal, GC may start later or earlier.

> Now we reset them at GC time.

> What do you think about it?

Not sure what you mean, we always ATOMIC_SIZE_EXCHANGE
malloc_increase to zero in gc_reset_malloc_info.
My patch also resets both counters (not 100% atomic because it's
two atomic operations, but I think it's OK as a hint).

Btw, I noticed I leftover a ssize_t usage in my patch
to gc_reset_malloc_info, will fixup if I commit this.

Unsubscribe: <mailto:ruby-core-request@ruby-lang.org?subject=unsubscribe>
<http://lists.ruby-lang.org/cgi-bin/mailman/options/ruby-core>

In This Thread