No more Locks! What can we achieve without the GIL
summary
Live demos measure raw effects not promises: a count to 10 million microbenchmark on a 32‑core laptop shows multithreading on stock CPython stays single‑core and gets slower, multiprocessing runs parallel but blows up memory, and an experimental free‑threaded Python 3.13 build puts CPU usage across cores and runs faster with the same code. Shared‑memory examples (naive matrix multiply) require copying or redesign to avoid races; using NumPy/GPU beats all pure‑Python approaches. Expect tradeoffs in GC, locking, and API changes.
AI-written summary · about
chapters (17)
- 0:00Introduction
- 1:08Concurrency and parallelism
- 2:29Global Interpreter Lock
- 3:58Single-threaded demo
- 5:03Multi-threaded demo
- 6:11Thread pool executor
- 9:04Threading limitations
- 10:09Threading for I/O
- 13:00Multiprocessing demo
- 14:51Python 3.13 free-threaded
- 17:46Memory usage comparison
- 19:13Thread-safe data sharing
- 21:02Embarrassingly parallel tasks
- 22:48Matrix multiplication
- 24:32When to use threads
- 25:58Python as orchestrator
- 26:45Q&A
related talks
21mInvestigating Managed Language Runtime Performance: Why JavaScript and Python...
42mOptimizing Code Performance for Python Internals
01h 13mTalk by I-Ting Angelina Lee (Washington University in St. Louis)
16mPricing Python Parallelism: A Dynamic Language Cost Model for Heterogeneous Platforms
16mIntrepydd: Performance, Productivity, and Portability for Data Science Application Kernels
23mVirtual Machine Design for Parallel Dynamic Programming Languages
41mHow to write a JIT compiler in 30 minutes
01h 21mPerformance Really Matters
