Python JIT
Python source → CPython bytecode → interpreter starts running it → JIT notices “this code runs a lot” → compiles that hot path to machine code → later calls jump to faster machine code
Python JIT / Numba mental model
Normal CPython:
Python source → bytecode → CPython interpreter executes bytecode`
With @numba.njit:
Python function -> Numba wrapper -> compile hot function to machine code -> run machine code
A decorator like:
@njit
def f(x):
return x * xCPython still runs the overall program. But inside the @njit function body, Numba can skip CPython bytecode interpretation and execute native machine code directly.