A "template interpreter" is a technique where machine code handler routines are generated for each bytecode opcode and mapped into a dispatch table.
High-performance runtimes like V8 Engine and HotSpot write their interpreters directly in assembly rather than C/C++.
- Performance (compilers struggle to optimize large switch-loop interpreters well)
- ABI compatibility with JIT (enables fast jumps for OSR, etc.)
Template Interpreters
A look at an under-discussed style of interpreter used by V8 and Hotspot.
https://zackoverflow.dev/writing/template-interpreters/

Seonglae Cho