julia
9b561eec - Compiler: narrow `interp` in `typeinf` loop (#63634)

Commit
2 days ago
Compiler: narrow `interp` in `typeinf` loop (#63634) interp = callee.interp` read the abstractly typed field, so the work loop dispatched on `AbstractInterpreter` while the frame was concrete. With more than one interpreter loaded (REPL's `REPLInterpreter`), inference then compiled every interpreter/state combination, e.g. `abstract_call_known(::REPLInterpreter, ..., ::InferenceState{NativeInterpreter})`. Narrow it with `::I`. To not box the now concrete interpreter again, pass the field to the dynamic `task(...)` call in `doworkloop` and avoid `applicable`/`===` against the abstract field in the `Future` asserts. Keep `typeinf_local` behind a `compilerbarrier`, called with the boxed field. A static call folds it and everything it reaches into one inference cycle with `typeinf`, and cycle members are neither inlined into each other nor called through their specsig, so e.g. `abstract_call` boxed the interpreter on every call. Add REPL completion warmups for splatting and `invoke`, which the mixed specializations used to cover by accident.
Author
Parents
Loading