IPC – Interprocess Communication

It is very important that processes have some way of communicating with each other. Operating systems provide such mechanisms, but we need to focus on issues related with it. For example, what if two processes in an airline reservation system are trying to sell the last seat on the plane at the same time? Of course, this is very wrong because you can't sell the same seat twice. There is also a dependency problem: if process A produces some kind of data and process B is reading that data (for example, to print it), then process B must wait until process A really produces the required data. The difference between processes and threads is that the first task for the thread is much easier to implement due to fact that ...

Get C++ Multithreading Cookbook now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.