
Oct. 29, 2012
4:46 p.m.
On Monday 29 Oct 2012, Richard Oudkerk wrote:
On Windows writes to pipes in message oriented mode are also atomic.
And even if it's part of the SUS, how do we know this is true for non-UNIX compatible systems?
We don't, but that isn't necessarily a reason to ban it as evil.
Hey, good idea I didn't say ban it, then hey? But if the OS cannot guarantee atomic writes (and enforce that size to ensure atomic writes for the system run under), then you cannot just say "Atomic writes mean we can have safely multiple threads accessing the pipe". The multiple access requires atomic access. If that cannot be guaranteed, then you cannot give multiple access.