[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: Boxed userdata and garbage collector
- From: Duncan Cross <duncan.cross@...>
- Date: Fri, 3 Sep 2010 19:10:33 +0100
On Fri, Sep 3, 2010 at 2:39 PM, Roberto Ierusalimschy
<roberto@inf.puc-rio.br> wrote:
> With the current incremental garbage collector, the collector is moved
> forward by allocations, that is, deltas in 'totalbytes', not by its
> absolute value. (The only effect that the absolute value of 'totalbytes'
> has on the collector speed is to make the collector slower, increasing
> the pause between collection cycles.)
>
> So, to mimic the effect of an external allocation as if it were
> internal, lua_gc(STEP, x) seems to be more than enough.
That's interesting, thank you for the clarification. Maybe it would be
a good idea to add a note about this to the documentation for
lua_newuserdata(), or somewhere in the next version of the manual/PiL.
-Duncan
- References:
- Re: Boxed userdata and garbage collector, Jonathan Castello
- Re: Boxed userdata and garbage collector, Sylvain Fabre
- Re: Boxed userdata and garbage collector, Jonathan Castello
- Re: Boxed userdata and garbage collector, Ted Unangst
- Re: Boxed userdata and garbage collector, Peter Cawley
- Re: Boxed userdata and garbage collector, Ted Unangst
- Re: Boxed userdata and garbage collector, Peter Cawley
- Re: Boxed userdata and garbage collector, Ted Unangst
- Re: Boxed userdata and garbage collector, Michal Kottman
- Re: Boxed userdata and garbage collector, Sylvain Fabre
- Re: Boxed userdata and garbage collector, Roberto Ierusalimschy