lua-users home
lua-l archive

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


Having linked together the modules I shall probably need in my 16-bit
Lua system, the .MAP file shows a code segment of 0xffdb, which means
that there are 37 bytes to go before I hit the ceiling.  Although this
may be a workable setup, I don't like to be so short of space.

Leaving out lauxlib, lbaselib, liolib and lstrlib brings the segment
size down to 0x8f45, so I can probably get some extra space by chipping
away at these libraries, commenting out functions I don't use.

But there must be people who have been in the same situation before. 
Maybe they have some advice to offer?  And maybe there are things that
can be commented out even in CORE?

FYI, I have already followed the advice in ltn002.

Then there is the data segment, which is also 64 KB.  I hope and pray
that the space left after heap, stack, etc. have been allocated will
suffice.  But I have my doubts when I see how much bytecode is produced
by relatively small source files.

It's possible to load code on the fly in Lua, but is it also possible to
unload or garbage-collect code that is no longer needed?  That would
solve my problem, since all the code does not have to be available at
the same time.

Grateful for any hint.
-- 
    Tore