|
|
|
|
|
by kenoph
1995 days ago
|
|
Yep. For a project at my company we are doing pretty much the same as the author's (though for another architecture) and we JIT basic blocks on the fly using LLVM + C helpers. Slightly OT, but even by JIT'ing + caching it's not always the case that your code run faster than a simple emulator. It sounds obvious written like this, but we were still surprised in some cases we encountered. But in our case it's probably related to the fact that the code we are jitting was not meant to be jitted, so we are doing some ugly things here and there. We also have to support self-modifying code (and that basically means blacklisting the jitter in some address ranges). TL;DR: even with LLVM, emulation is often faster. QEMU tcg is likely faster than both, but it's GPL'd. EDIT: wanted to add that LLVM JIT infrastructure is still moving quite a bit. |
|