lua-users home
lua-l archive

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


> Lua uses a non-copying, non-moving mark and sweep garbage 
> collector. Your pointers are safe. As for the future, I'll 
> leave that up to the makers of Lua.

We have no plans for a copying collector (or any other "moving"
collector).

Anyone concerned about fragmentation should read
"The Memory Fragmentation Problem: Solved?"
(http://www.cs.utexas.edu/users/wilson/papers/fragsolved.pdf), and
eventually change his malloc library.

  This paper substantially strengthens the original fragmentation results
  presented in our earlier allocator survey, showing that for a variety of
  applications, good allocators exhibit nearly zero fragmentation---about
  one percent on average, for 8 varied C and C++ programs. While it
  is clear that there must exist some programs for which this is not
  true, it shows that the received view of the fragmentation problem is
  simply wrong, and fragmentation is not the kind of problem 30 years of
  research generally assumed it was---typical program behavior is very
  favorable to several clearly excellent allocation policies, due to
  strong regularities in program allocation and deallocation behavior.

-- Roberto