Inter Process Communication (IPC)

A process can be of two types:

An independent process is not affected by the execution of other processes while a cooperating process can be affected by other executing processes. Though one can think that those processes, which are running independently, will execute very efficiently, in reality, there are many situations when cooperative nature can be utilized for increasing computational speed, convenience, and modularity.

Inter Process Communication (IPC) is a mechanism that allows processes to communicate with each other and synchronize their actions. The communication between these processes can be seen as a method of cooperation between them. Processes can communicate with each other through both:

  1. Shared memory
  2. Message passing

https://s3-us-west-2.amazonaws.com/secure.notion-static.com/6b43d383-0e34-4cff-931a-d81cc150389c/Untitled.png

Figure 1 shows a basic structure of communication between processes via the shared memory and via the message passing method.

An operating system can implement both methods of communication. Communication between processes using shared memory requires processes to share some variable, and it completely depends on how the programmer will implement it.