lua-users home
lua-l archive

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


>> I understand, that there is no official documenation about the
>> underlying bytecode and the VM?! Or is there?
>
> http://www.lua.org/source/5.1/lopcodes.h.html
> http://www.lua.org/source/5.2/lopcodes.h.html
>
> That's all there is.

There is also
http://luaforge.net/docman/83/98/ANoFrillsIntroToLua51VMInstructions.pdf
which is helpful.

I have written a small Lua 5.2 bytecode parser in LuaJIT:
https://github.com/catwell/lualua But basically the best way to study the
5.2 bytecode is probably to start from the source code of luac (especially
dump.c),

-- 
Pierre 'catwell' Chapuis