Debuggers actually set breakpoints after the function prologue, but reliably identifying the prologue across compilers and optimisation levels is hard!
miniblog.
Related Posts
Implementing interactive languages, and the tradeoffs of interpreters, JIT compilers, and AOT compilers:
Interpreters versus compilers as a spectrum, and a fun worked example of optimising Brainfuck:
It's strange how AOT compilers usually have different modes for optimising time or space usage, but JITs rarely have modes like "prefer fast startup".
The vast majority of JITs seem to focus on runtime of hot code after warming up.