lua-users home
lua-l archive

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



> > Eek, we don't want (or need) concurrency!
> 
MR> Whereas I've been toying with the idea of putting a 
> low-priority thread in Lua which implements a treadmill Just 
> Because It Would Be Cool.  :-)

Sounds interesting. I havent really used threads a lot; a problem
springs to mind. What would happen if you had a really intensive period
of processing, which required objects to be GC'd. If the low priority
thread only got called a couple of times it might not collect enough
garbage. Would it lag further and further behind? If you were on a
restricted memory system, couldn't you run out of memory? Would you end
up having to do more work in the low priotiy thread to clear out more of
the garbage? This probably works fine on a not-too-intensive system with
plenty of memory.

Given an incremental system I take it the amount of time spent
collecting will have to be adjusted proportionally to the lack of memory
on a limited memory system. Also, because of the nature of IGC I think
we are going to do more work to collect the same number of objects (as
objects will revert to grey/neutral) as the current system. So,
generational IGC could be a big saving?

/Nick