Why Chrome Tab Crashes Are Isolated: Inside Inter-Process Communication
This article explains how processes communicate via shared memory and message passing, using Chrome's multi-process architecture as a case study to show why a single tab crash doesn't bring down the entire browser, and covers OS mechanisms like pipes, sockets, and Mach ports.
Reading font

Introduction: Processes Need to Cooperate
A process is more than loaded code; it includes CPU state, memory regions, open files, and I/O devices. The OS isolates processes by giving each its own address space and enforcing access control via privileged instructions. If a process tries to access another's memory, the OS terminates it. However, many tasks require cooperation — parallel computation, modular design, or fault isolation — so processes must exchange data through Inter-Process Communication (IPC).
Shared Memory Model
Shared memory lets multiple processes access the same physical memory region. The OS creates the region via a system call in the creator's address space; other processes map it into their own spaces via another system call. Once mapped, processes read and write the region directly. The OS does not manage data layout or synchronization — developers must agree on data formats, offsets, and concurrency control.
Example: Producer–Consumer with a Shared Array
A producer writes 8-bit signed integers into a shared array; if the consumer reads them as 8-bit unsigned integers, the bit patterns are identical but the interpreted values differ. Misaligned reads (e.g., reading 32-bit unsigned integers from an 8-bit array) or reading from wrong offsets also cause misinterpretation. Simultaneous writes to the same location create race conditions, leading to undefined behavior.
Case Study: Chrome's Multi-Process Architecture
Chrome (and all Chromium-based browsers) uses three process types:
Browser process — manages UI and I/O; created once at startup.
Renderer processes — handle HTML, JavaScript, images; typically one per tab.
Plugin processes — manage Flash, QuickTime, PDF readers, etc.
This isolation ensures a JavaScript bug or crash in one renderer only kills that tab's process, not the whole browser. The renderer processes communicate with the browser process via IPC (shared memory and message passing) to render pixels, handle input, and manage resources.
Other shared-memory users include simulation software, game engines, database systems, and deep-learning frameworks.
Message Passing Model
Message passing avoids shared memory by letting the OS mediate communication. Each process has its own address space; they send/receive messages through OS-provided primitives: pipes, sockets, and remote procedure calls (RPC). The kernel creates a queue (a "mailbox") in its own address space. Process A sends a message via a system call; the kernel copies it into the queue. Process B receives via another system call; the kernel copies the message out.
Queues can be configured for:
Asynchronous communication (sender/receiver need not wait).
Buffered queues with capacity limits.
Full-duplex via two queues (one each direction).
Mach Ports and Port-Based Communication
The Mach kernel (basis for iOS/macOS) introduced "tasks" (processes) and "ports" (mailboxes). Messages are sent to ports, not directly to tasks. A task can hold multiple ports, and a port can be shared by many tasks. A listening port accepts connection requests and establishes private communication channels. This design influenced modern microkernel architectures.
Network Transparency and Sockets
Because message passing doesn't require shared address spaces, it works across networked machines. The OS handles network drivers, packet routing, and hardware details; developers use the same send/receive APIs. The socket interface is the de facto standard for client–server communication (HTTP, SSH, etc.). Client and server processes may run on the same machine (localhost) or different machines; IP addresses identify the host, ports identify the listening endpoint.
Mach's port abstraction and the socket API both demonstrate how OS-provided message passing enables scalable, fault-tolerant, and distributed systems.
For questions about attribution, corrections or content rights, please contactand we will review it promptly.