The GVL (Global VM Lock, formerly GIL) in MRI Ruby allows only one thread to execute Ruby code at a time — so threads don't provide true CPU parallelism. But the GVL is released during I/O, so threads do help for I/O-bound work. For CPU parallelism, you use multiple processes. This mirrors Python's GIL situation.
The GVL: one thread runs Ruby code at a time
MRI (the standard Ruby) has a GLOBAL VM LOCK:
→ only ONE thread executes Ruby code at any instant (no CPU parallelism from threads)
→ BUT the GVL is RELEASED during blocking I/O (network, file, DB)
So: threads help for I/O-bound work, NOT for CPU-bound work.
