[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: Execution of bytecodes
- From: Roberto Ierusalimschy <roberto@...>
- Date: Fri, 2 Oct 2015 09:49:59 -0300
> A similar feature that has been asked before is to do that for
> strings, for example to use read-only memory on low-RAM platforms. I
> believe eLua has such a feature, and IIRC Roberto mentioned it (in a
> recent workshop video) as a potential future feature for Lua. If that
> ever makes it into Lua for strings, it would be nice to have the same
> option for bytecode. But on the other hand, contrary to strings, the
> runtime memory layout of the function prototypes may not be exactly
> that of the serialized bytecode.
We could reuse only the bytecode array (and lineinfo array, if present).
This is usually the bulk in large functions. (Currently Lua copies
everything into the interpreter. It never keeps pointers to outside
memory.)
-- Roberto