1. The OS PCB (Process Control Block)
The OS tracks every running program using a unique data structure called a PCB.
- Every time a true Process starts, the OS creates a new PCB row, assigns a unique PID, and allocates physical RAM blocks.
- Threads do not get unique PCBs or memory. They live inside an existing process and share its RAM.
2. Legacy Browsers (Tabs = Threads)
Old browsers ran the entire application as a single OS Process.
- Every tab you opened was just a Thread inside that one Process. Therefore, they shared the exact same memory heap.
- The Fatal Flaw: If Tab 2 encounters a bug (Segfault), it corrupts the shared memory. The OS kills the entire Process, taking the whole browser down with it.
3. Modern Chrome (Tabs = Processes)
Chrome acts like a "Mini-OS" by using isolated processes.
- Browser Process: The manager. It handles UI, Network, and Disk.
- Renderer Processes: Every single tab requests a brand new, isolated OS Process with its own unique PCB and RAM.
- If a tab crashes, the OS only kills that specific PCB. The rest of the browser survives!
4. Inter-Process Communication (IPC)
If tabs are isolated in sandboxes, how do they load websites?
- Because Renderers are sandboxed, they are strictly forbidden from touching the OS Network card.
- They must shoot a serialized message across an IPC Pipe to the main Browser Process. The Browser Process makes the secure OS Syscall and hands the data back down the pipe.