Platform/Features/IonMonkey
Feature |
Status |
ETA |
Owner |
IonMonkey |
Modern JIT Compiler for JavaScript |
Unknown |
David Anderson |
Summary
IonMonkey is a new JIT for SpiderMonkey. Our goal is to implement a new compiler to enable many new JavaScript optimizations. In particular IonMonkey will feature much more organized and explicit data structures typical of advanced compilers. This goal of being clean and flexible will be extremely important for future optimization work and experimentation.
Team
Who's working on this?
- Lead Developers: David Anderson, David Mandelin
Release Requirements
Complete checklist of items that need to be satisfied before we can call this feature "done".
- Does not regress correctness.
- Does not regress usability or bench-marketing performance.
Next Steps
- Immediate worklist:
- Prototype model backend (bug 646923)
- Design and implement new IRs (bug 650181)
- Create a code generator and simple register allocator
- Long-term worklist:
- Implement method inlining
- Implement advanced linear-scan register allocation
- Implement loop invariant code motion
- Implement constant sub-expression elimination
- Implement type-profiling
- Implement enough functionality to replace existing JITs
- Implement proper memory management of code
- Implement interval analysis
Designs
See bug 646923 for an experimental design in Python, and bug 650181 for IR plans.
Goals
- Provide a backend that can match or beat the Trace JIT or Crankshaft in speed. Sub-goals:
- Fine-grained specialization and de-specialization.
- Integration with type inference.
- Clean, textbook IR so optimization passes can be separated and pipelined with well-known algorithms.
- Document and comment well so the implementation and its side effects can be easily understood.
- Recompilation, debugging, bailouts are all related - and should be solved up-front.
- First SpiderMonkey JIT that starts off with peer reviews!
- (Unknown feasibility) Act as a baseline compiler to replace JM2.
- Manage memory much better, in part to avoid range problems on x64.
Avoiding these...
- Aggressive stores. We should move state syncing to bailout points.
Please remove this line and any non-relevant categories below. Add whatever other categories you feel are appropriate.