Game of Loom: implementation patterns and performance implications
summary
Compares Java Project Loom virtual threads versus native threads by implementing Conway’s Game of Life with a CSP style channel per cell and variants including one-thread-per-cell and grouped workers on a ~5,000-cell board. Measures include different channel implementations (blocking, single-value, lock-free) and thread pools; virtual threads win some workloads—one benchmark shows about 7× faster—but suffer from more context switches, cache/core migration and sensitivity to blocking channel design, so performance depends on channel implementation and mapping of virtual threads to carriers.
AI-written summary · about
chapters (7)
- 0:00Project Loom intro
- 7:13Virtual threads solve Java issues
- 16:21Virtual vs native threads perf
- 26:53Game of Life with Loom
- 33:04Synchronization patterns in virtual thread applications
- 41:08Benchmarking Loom channels
- 47:50Loom: tool not silver bullet
related talks
47mGame of Loom: implementation patterns [...] playing with virtual threads
51mGame of Loom: implementation patterns and performance implications playing with
31mJava Virtual Threads
47mThe Challenges of Introducing Virtual Threads to the Java Platform - Project Loom
47mGame of Loom 2: life and dead(lock) of a virtual thread
51mWhat's Looming in Java The Why and What of Project Loom
01h 13mProject loom: Modern scalable concurrency for the Java platform
35mUntangled: Sneak peek at Project Loom
