Unix philosophy

gwyn at brl-vld gwyn at brl-vld
Thu Sep 22 06:28:33 AEST 1983


From:      Doug Gwyn (VLD/VMB) <gwyn at brl-vld>

The important thing about pipes is that for ordinary purposes a process
does not have to be concerned whether a file descriptor it is using is
attached to a file, a pipe, or a special file (device).  This is not
true of many other IPC schemes.

Another nice thing about pipes is that they are file system entities,
so fstat() works on them.  However, 4.1cBSD (and I am told 4.2BSD)
changed pipes to be socket pairs and return a bogus (struct stat) on
pipes.  This needs to be fixed, at least to the extent that (device,
inode) is unique for each pipe.

I actually liked pipes that were genuinely part of the file system;
named pipes (FIFOs) and pipes are integrated into UNIX System III and V
very cleanly.  It would seem that with good block buffer handling this
would still be a good scheme even in the presence of other IPC
mechanisms.  I think Berkeley had in mind piping between processes on
separate CPUs when they changed to socket pairs.



More information about the Comp.unix.wizards mailing list