[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: Ever-Increasing Memory Usage in 5.0
- From: roberto@... (Roberto Ierusalimschy)
- Date: Tue, 11 Apr 2006 09:47:22 -0300
> If I alternate g_collectNOW between false for a while (memory grows),
> then to true (gc every frame), the level that memory drops to for each
> gc-each-frame section is higher than the previous. Memory seems to be
> being irretrievably leaked.
I assume your userdata has __gc metamethods, is that right? Then, they
are collected in two phases: in a first GC cycle, their metamethods are
called; only in the next cycle they are actually deallocated (if the
metamethods did not "ressurect" them). That may (or may not :) explain
part of that behavior.
-- Roberto