lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


I am having trouble with Lua garbage collection. I am using Lua as an agent
system for a real time game. Basically the mark and sweep system takes to
long. Having a small threshold requires garbage collecting regularly, which
means marking a lot of data regularly and cleaning up a little of it. The
marking takes to long to do so regularly. Having a high threshold requires
marking less regularly which is better but cleaning up loads of data in one
sweep, which takes to long. There is no good balance here. Has anyone found
a way around this?