Mozilla’s new JägerMonkey engine will continue to use nanojit for some things, but will rely on Apple’s Nitro Assembler to generate efficient native code. This will allow JägerMonkey to benefit from the performance advantages of method-based just-in-time (JIT) compilation. JägerMonkey will also use tracing optimization to flatten out loops and speed up other kinds of execution paths that can benefit from further optimization. Mozilla says that this blend of technologies potentially offers the best of all worlds.
“The reason we’re [building JägerMonkey] is that TraceMonkey is very fast for code that traces well, but for code that doesn’t trace, we’re stuck with the interpreter, which is not fast. The JägerMonkey method JIT will provide a much better performance baseline, and tracing will continue to speed us up on code where it applies,” wrote developer David Mandelin a blog entry about the new engine.
The project is said to be at a relatively early stage of development and is not yet ready to be broadly demonstrated. Developers who want to have a look at the code can download it from Mozilla’s version control repository. The current development status is described in a page at the Mozilla wiki.