Asger Ottar Alstrup a écrit :
Hi,
We would like to do this, and have a few questions. Would the core not
be to make a standalone compiler from the neko bytecode to LLVM bytecode?
In other words, basically translate the code in interop.c into LLVM code
and splice that together, similar to how the PHP LLVM target was
bootstrapped?
http://llvm.org/devmtg/2008-08/Lopes_PHP-JIT-InTwoDays.pdf
I guess the most easy would be to rewrite vm/jit_x86.c by using LLVM.
Right now, each Neko opcode generates the corresponding x86 code without
any kind of global optimization pass.
Using LLVM should significantly improve the speed of the JIT, and would
enable to save the resulting optimized code as a standalone executable.
Nicolas
--
Neko : One VM to run them all
(http://nekovm.org)