The MAKE_WARM micro-op is inserted into every piece of jitted code and within the loop if there is one.
So it needs to be cheap.
Currently, it does this:
current_executor->vm_data.warm = true;
if (--tstate->interp->trace_run_counter == 0) {
_Py_set_eval_breaker_bit(tstate, _PY_EVAL_JIT_INVALIDATE_COLD_BIT);
}
we should move the logic for testing for "coldness" onto a less frequently taken path, perhaps in the jit itself, so _MAKE_WARM just needs to do the "warming":
current_executor->vm_data.warm = true;
Linked PRs
The
MAKE_WARMmicro-op is inserted into every piece of jitted code and within the loop if there is one.So it needs to be cheap.
Currently, it does this:
we should move the logic for testing for "coldness" onto a less frequently taken path, perhaps in the jit itself, so
_MAKE_WARMjust needs to do the "warming":Linked PRs
Tools/jit/trampoline.c#139904MAKE_WARM#143827