Interprocess Communication in Operating System
There are 2 types of process -
- Independent Processes - Processes which do not share data with other processes .
 - Cooperating Processes - Processes that shares data with other processes.
 
Cooperating process require Interprocess communication (IPC) mechanism. Inter Process Communication is the mechanism by which cooperating process share data and information.
There are 2 ways by which Interprocess communication is achieved -
- Shared memory
 - Message Parsing
 
Let’s look at few of the important points of each .
Shared Memory
- A particular region of memory is shared between cooperating process.
 - Cooperating process can exchange information by reading and writing data to this shared region.
 - It’s faster than Memory Parsing, as Kernel is required only once, that is, setting up a shared memory . After That, kernel assistance is not required.
 
Message Parsing
- Communication takes place by exchanging messages directly between cooperating process.
 - Easy to implement
 - Useful for small amount of data.
 - Implemented using System Calls, so takes more time than Shared Memory.