[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: Compile LUA Opcodes
- From: "Jason P" <ahq_ranger@...>
- Date: Thu, 02 Oct 2003 19:23:44 -0400
I don't know if anyone else would be interested, but I would like to see a
dynamic JIT style compiler for LUA opcodes to machine code. It would be
callable inside the LUA via a 'JIT_Compile(<function>)' interface perhaps?
This is one method I have thought about implementing:
Look through/Learn the LUA internal Opcode C Source.
Bundle TinyCC with LUA.
Write a routine to parse LUA opcodes into one C source program, wrapped as a
Pass that program to TinyCC to compile dynamically.
Get the function symbol back from TinyCC and register it with LUA.
Of course, writing the opcodes into assembly would be easier, but I figured
TinyCC could offer a nice portable solution since it has support for various
High-speed Internet access as low as $29.95/month (depending on the local
service providers in your area). Click here. https://broadband.msn.com