What is a Process?
Think Of It Like Separate Apartments
Each process is like an apartment in a building. Your apartment has its own rooms, furniture, and stuff. Your neighbor cannot walk into your apartment and move your couch. The walls (enforced by hardware) keep everyone separate.
Why Isolation Matters
Crashes stay contained: If your neighbor apartment catches fire, yours does not burn. Similarly, if one process crashes, others keep running. Your music player crashing does not kill your browser.
Security: A sketchy app cannot read your banking app memory. The walls between processes are real, enforced by the CPU itself.
The Cost of Separate Apartments
Moving in is expensive: Creating a new process takes 1-10 milliseconds. The OS must set up a whole new address space.
Talking to neighbors is slow: Since processes cannot share memory, they must communicate through the OS - pipes, sockets, files. This adds overhead.
Switching apartments takes time: When the CPU switches from one process to another, it takes 10-100 microseconds to swap all the memory mappings.