The GIL, threading, asyncio, and multiprocessing — picking the right tool
The GIL explains why multithreading doesn't speed up CPU-bound Python work — a fact that surprises many developers. Picking the wrong concurrency model can make performance worse, not better, and this comes up in system design rounds when discussing parallel data fetching, serving ML models under load, or writing efficient ETL pipelines.
The GIL (Global Interpreter Lock) is a mutex inside CPython that allows only one thread to execute Python bytecode at a time. For IO-bound work (waiting on network/disk), threads release the GIL during the wait — multiple threads genuinely help. For CPU-bound work, threads fight over the GIL and don't help at all.
Both executors expose the same map / submit API — switching from threads to processes is often just changing one class name.