[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: lua garbage collection
- From: Dimitris Papavasileiou <jimmyp@...>
- Date: Thu, 25 Sep 2003 13:23:34 +0300
Hi,
I was thinking of using lua to handle data files as well, that is make data
files like textures, models etc. lua files and have the interpreter load
them instead of writing parsers for everything. Anyway this is really neat
but I'm running into a potential problem: After loading the files and
getting them from lua some of them (like texture files) will not be useful
any more and since they might be quite big they'll waste quite some memory.
So the question is: if I GC those data will the memory be returned to the
system to be used by other processes? I somehow doubt that but even then,
assuming that this memory was reserved by lua (or my process not sure about
this) and not used wouldn't th VM manager soon swap these pages out and use
the memory for more useful pages? What I want to say is: in any case I won't
waste physical RAM will I?
Thanks,
Dimitris