VM Design Choices
summary
HotSpot evolves from a single-threaded Self port into a complex VM where choices matter: an untrusted JNI call costs ~40–50 instructions because of handle shuffles and stack/PC stores; a stage zero JIT (template code) speeds startup at the cost of bulk code; safe points plus a compact state map let the server compiler stretch optimization regions and enable a deoptimization that inlines non-final methods without a static “line in the sand”; heavyweight C2 with a graph-coloring allocator and safe points yields C-like peak performance; frame-adapter stacks and C++ mixed oops are painful and avoided now.
AI-written summary · about
chapters (34)
- 0:00Intro
- 1:18The nature of this talk
- 2:20Choices to make
- 3:15Obvious choices
- 5:26Interpreter choices
- 6:50Optimization choices
- 8:30Stage Zero Jets
- 9:27GC Choices
- 10:39Safe Points vs Stop Anywhere
- 13:23Multithreading
- 15:48Atomic Operations
- 19:11Native Calls
- 21:18Native oops
- 21:58Hiding oops
- 22:14Stack Crawls
- 23:27Active GC
- 23:58Night Calling Convention
- 24:42Native Call
- 26:15Safe Points
- 28:40Heavyweight
- 34:59Debugging Flags
- 36:40Thin Locks
- 37:31Java Memory Model
- 39:15Deopt
- 39:52Inline Cache
- 42:40HotSpot
- 43:50Azula
- 44:49TLB
- 45:48ThreadLocal Storage
- 47:22Transactional Memory
- 52:17Safepoints
- 54:20Adapter frames vs Frame adapters
- 55:19Inlining constant OOP
- 56:22Locking objects
related talks
01h 01mAn Introduction to JVM Performance
49mAn Introduction to JVM Performance
54mJava performance techniques The cost of HotSpot runtime optimizations
35mJava at Speed: Building a Better JVM
41mAn Introduction to JVM Performance
59mAn Introduction to JVM Performance
01h 09mFrom Bytecode to Native Code in HotSpot JVM
46mJIT Compiler From the Ground Up
