|
On 10/02/2015 12:01 PM, Marc Balmer wrote:
In my application, I am reusing the same buffer that I pass to lua_loadXXX many, many times. So I can empirically ensure you that the byte code is copied.When I pass precompiled Lua bytecode to Lua using lua_loadXXX functions by passing a pointer to the bytecode in memory (e.g. after mmaping the file containing the byte code into memory), will that directly be used or will there new memory be allocated and the bytecode be copied? - Marc
You can also test this by adding a breakpoint or print in your lua_Alloc function.
-- Thomas