| 127 | |
| 128 | == Allison's thoughts while reviewing unladen-swallow == |
| 129 | * Basic idea is to dynamically generate LLVM IR from a PIR sub, then store the compiled code object within the sub to run instead of following the opcode runloop. |
| 130 | * Each opcode has a LIR "template", which can be combined in series (with substitutions for literals, variables, etc) to generate the full LIR body. |
| 131 | * Some callsites in the PIR code can be JIT-ed to direct C function calls, completely eliminating the PCC overhead. |
| 132 | * Added win for caching the JIT-ed subs between runs of the interpreter (in LIR form if necessary, or compiled form if possible), as the big cost is compiling them. |