Open
Description
Currently the JIT works in the following passes:
- Create a trace (by projecting from the current point of execution)
- Convert global variables to constants
- Type based redundancy elimination
- Peephole redundancy elimination
- Create executor
What we want is:
- Create a trace and redundancy elimination
- Partial evaluation
- Create executor
To get there we need to combine current steps 1-4 into a single step and implement the partial evaluator. The partial evaluator is discussed elsewhere, this issue is about combining the earlier passes.
To do this, we want to:
- Refactor the symbol structs used in the type analysis to make them more robust and easier to use. See Refactor the JIT's type-lowering/specialization pass's data structures. faster-cpython/ideas#706
- Merge passes 2-4 into a single pass
- Merge that pass into pass 1, using the type information to guide trace projection